The Nasdaq index broke through the 6,000 level for the first time, as stocks were buoyed by some strong company results.
The Nasdaq index closed up 41.67 points, or 0.7%, at 6,025.49, powered by gains in index heavyweights Apple and Microsoft.
On the Dow McDonald's shares jumped 5.6% after beating profit estimates.
Caterpillar shares rose after better-than-expected quarterly results.
The company said revenue rose 3.8% to $9.82bn in the first three months of the year, and it now expects full-year revenues of $38bn-$41bn, compared with an earlier forecast of $36bn-$39bn.
Caterpillar was the biggest riser on the Dow Jones, with the Dow up 232.23 points at 20,996.12.
The Dow was also bolstered by McDonald's. Profits in the first quarter of the year rose 8% to $1.21bn.
Sales at McDonald's US restaurants that have been open for more than 13 months were up 1.7%, beating analysts' expectations of 1.3%.
The S&P 500 index rose 14.46 points to 2,388.61.