* Fed raises rates as expected
* Facebook gains after two days of steep losses
* Energy stocks jump as oil prices rise more than 2 pct
* Dow down 0.18 pct, S&P 500 down 0.18 pct, Nasdaq down 0.26 pct (Updates to market close)
NEW YORK, March 21 (Reuters) - U.S. stocks ended slightly lower on Wednesday, with major indexes giving up gains in choppy trade after the Federal Reserve raised U.S. interest rates, while a strong gain in the energy space helped limit losses.
The Fed raised interest rates and forecast at least two more hikes for 2018, signaling growing confidence that U.S. tax cuts and government spending will boost the economy and inflation and lead to more aggressive future tightening.
The hike was widely expected, and new Fed Chairman Jerome Powell said in a news conference after the rate-hike announcement that the U.S. central bank was trying to take the "middle ground" in raising rates.
"That's a Fed that really feels good about the economy, not only this year but into next year," said Jim Paulsen, Chief Investment Strategist at The Leuthold Group in Minneapolis.
"The initial response by equities was to go up because of the confidence the Fed seems to have in the economy. But with bond yields going up in anticipation of more hikes ..., that kind of scared the stock market again."
Financials, which benefit from a higher rate environment, briefly extended gains in the wake of the announcement but lost ground to close down 0.03 percent. Names sensitive to higher rates such as utilities, down 0.39 percent, and real estate, off 0.93 percent, were under pressure.
Stocks were choppy following the Fed announcement, as yields on the 10-year U.S. Treasury note moved closer to 3 percent, touching a one month high of 2.936 percent.
Stocks have struggled this year while bond yield have moved higher.
Energy jumped 2.63 percent and helped lift equities for a second straight session. Crude oil prices hit a six-week high after a surprise decline in U.S. inventories and as concern persisted over possible disruption to Middle East supply.
Markets participants are still trying to decipher the number of rate hikes this year - whether the Fed will stay at three increases as previously forecast by policy makers, or whether a fourth hike is possible.
The Dow Jones Industrial Average fell 44.96 points, or 0.18 percent, to end at 24,682.31, the S&P 500 lost 5.01 points, or 0.18 percent, to 2,711.93 and the Nasdaq Composite dropped 19.02 points, or 0.26 percent, to 7,345.29.
Facebook shares gained 0.74 percent to stem its recent sell-off over the past two days, which cost the social media company about $50 billion in market value after reports of data misuse that raised broader questions about consumer privacy and the need for tougher regulation.
The company chief executive, Mark Zuckerberg, said Facebook "made mistakes" in a statement.
General Mills slumped 8.85 percent after the company cut its full-year profit forecast due to higher freight and commodity costs.
That weighed on other food companies, with Kellogg off 3.98 percent, JM Smucker down 4.20 percent and ConAgra off 2.94 percent.
Southwest Airlines fell 4.79 percent after the carrier cut its forecast for a key revenue metric. Other airlines also fell, with the NYSE Arca Airline index down 1.09 percent.
Advancing issues outnumbered declining ones on the NYSE by a 1.35-to-1 ratio; on Nasdaq, a 1.49-to-1 ratio favored advancers.
Volume on U.S. exchanges was 6.72 billion shares, compared to the 7.16 billion average over the last 20 trading days.
(Additional reporting by Sinead Carew Editing by Nick Zieminski and James Dalgleish)