NEW YORK ( TheStreet) -- In a little over three years as a public company, Facebook (FB) is now worth more than Wal-Mart (WMT) and has replaced the retailing giant as one of the 10 largest companies in the Standard and Poor's 500 Index by market capitalization.

During the past year, Facebook's stock has jumped roughly 30% as the broader S&P 500 has barely managed to keep its head above water. The climb has added more than $65 billion to Facebook's market value, bringing it to more than $238 billion, just above Wal-Mart's $235 billion. Shares of Wal-Mart are down 20% from their 2015 high, which was reached in January, and they recently hit a 20-month low.

By revenue, Wal-Mart is the largest company in the world, with sales of $476 billion in the company's latest fiscal year ended in January. Facebook recorded revenue of roughly $12.5 billion in 2014.

Wal-Mart hasn't finished a year outside the top 10 biggest S&P 500 companies by market cap since 1997, said S&P Dow Jones Indices' Howard Silverblatt.

On Tuesday, shares of Facebook were trading at $85.31, up 57 cents. Wal-Mart was down 8 cents to $72.71.

More from Investing

Inside Carnival's Mind Blowing New Horizon Cruise Ship (Video)

Inside Carnival's Mind Blowing New Horizon Cruise Ship (Video)

Neel Kashkari: The Heart of Our Financial System Is More Radioactive Than Ever

Neel Kashkari: The Heart of Our Financial System Is More Radioactive Than Ever

McDonald's Criticized for Not Doing More in Wake of Sexual Harassment Claims

McDonald's Criticized for Not Doing More in Wake of Sexual Harassment Claims

Finding Stocks Right for You: Cramer's 'Mad Money' Recap (Friday 8/25/18)

Finding Stocks Right for You: Cramer's 'Mad Money' Recap (Friday 8/25/18)

Jim Cramer: The 10-Year Yield Could Go to 2.75%

Jim Cramer: The 10-Year Yield Could Go to 2.75%