NEW YORK - U.S. stocks rallied to a higher close on Friday and benchmark Treasury yields dipped at the end of a week marked by strong earnings, wrapping up a solid month with data confirming inflation is cooling, which could allow the Federal Reserve to pause after next week's expected rate hike.

All three major U.S. stock indexes advanced, but a drop in Amazon.com shares capped the Nasdaq's gains.

Each index posted weekly gains, and while the S&P 500 and the Dow ended the month higher, the tech-laden Nasdaq was essentially unchanged from its March 31 close.

"It’s the last day of a fairly solid month, along with the realization that this earnings season continues to impress," said Ryan Detrick, chief market strategist at Carson Group in Omaha. "You’ve seen some really big companies step up with impressive earnings, pushing back on the narrative that we are headed directly into recession."

That narrative got the session off to a rocky start after Amazon.com Inc warned of a potential slowdown, echoing Thursday's weaker-than-expected first-quarter GDP data.

But economic data released before the bell confirmed that inflation is falling but remains well above the Federal Reserve's average annual goal of 2%, and did little to move the needle regarding market expectations of another 25 basis-point interest rate hike when the central bank meets next week.

"The core PCE came in as expected still showing that inflation is coming back to earth," Detrick added. "This potentially opens the door for one more rate hike next week and the Fed can pause the aggressive tightening that we’ve seen since last March."

The Dow Jones Industrial Average rose 272 points, or 0.8%, to 34,098.16, the S&P 500 gained 34.13 points, or 0.83%, to 4,169.48 and the Nasdaq Composite added 84.35 points, or 0.69%, to 12,226.58.

European shares staged a late-session rebound, and closed the books on April with a 1.9% monthly advance.

The pan-European STOXX 600 index rose 0.56% and MSCI's gauge of stocks across the globe gained 0.66%.

Emerging market stocks rose 0.50%. MSCI's broadest index of Asia-Pacific shares outside Japan closed 0.52% higher, while Japan's Nikkei rose 1.40%.

Treasury yields fell on signs of cooling inflation.

Benchmark 10-year notes last rose 24/32 in price to yield 3.4371%, from 3.528% late on Thursday.

The 30-year bond last rose 47/32 in price to yield 3.6733%, from 3.756% late on Thursday.

The greenback advanced against a basket of world currencies on the heels of the inflation data, and benefitting from the yen plunging after the Bank of Japan maintained its low policy rate.

The dollar index rose 0.13%, with the euro down 0.08% toat $1.1018.

The Japanese yen weakened 1.66% versus the greenback at 136.24 per dollar, while Sterling was last trading at $1.2565, up 0.62% on the day.

Oil prices jumped after data showed U.S. crude output slowing and fuel demand strengthening.

U.S. crude jumped 2.70% to settle at $76.78 per barrel, while Brent settled at $79.54 per barrel, rising 1.49% on the day.

Gold prices were nominally as Treasury yields dipped and concerns persisted over the U.S. banking turmoil.

Spot gold was up 0.05% at $1,988.75 an ounce.

(Reporting by Stephen Culp in New York Editing by Matthew Lewis and Diane Craft)