Traders were encouraged by earnings gains and a decline last week in the number of people applying for unemployment benefits.
The S&P 500 rose five points, or 0.3 percent, to close at 1,992 Thursday. That's four points above the record close it reached July 24. The Dow Jones industrial average gained 60 points, or 0.4 percent, to 17,039. The Nasdaq composite edged up five points, or 0.1 percent, to 4,532.
Hewlett-Packard rose 5 percent after the company reported its first sales increase in nearly three years. Sears fell 7 percent after reporting a wider loss.
Bond prices rose. The yield on the 10-year Treasury note fell to 2.40 percent.