After zigzagging in and out of positive territory, the Dow Jones Industrial Average rose 28.49 points (0.32 per cent) to 8799.41 at the market close.
The tech-studded Nasdaq fell 3.57 points (0.19 per cent) to 1858.80 and the broad-market Standard & Poor's 500 index edged up 1.30 points (0.14 per cent) to a preliminary close of 946.19.
"We are witnessing the epitome of a range-bound market," said Patrick O'Hare of Briefing.com.
Trading volume and news flow were sparse ahead of the weekend.
Investors shrugged off the University of Michigan's consumer sentiment index showing a gain in June for the fourth month running that was slightly below market expectations.
"The report suggests that the recent improvements in economic data are helping sentiment but some concerns about inflation and the impact of higher interest rates on the recovery in the economy may be beginning to creep into the equation," Charles Schwab & Co. analysts said in a client note.