This hasn’t been a good year for the equities market. The S&P 500 is down nearly 20% and with two trading days left in the year, investors’ hopes of a miraculous recovery have been dashed.

But even when the overall market is losing, there are still winners — and there were quite a few of them this year — mostly in energy, which has been the best-performing sector of 2022.

Here are the big winners, and losers, of the year.

The winners

The story of 2022 has been energy.

Brutally high oil and gas prices were the talk of the town this year and one of the largest contributing factors to sky-high inflation. That’s bad news for drivers, but ended up being great for the energy industry as oil prices and energy stocks are closely interlinked.

The energy sector has so far returned more than 60% this year, significantly outperforming every other S&P 500 sector. No other sector has gained even 5% year-to-date.

Occidental Petroleum has been the biggest gainer of the year in the S&P 500, up 122% year-to-date.

Constellation Energy is in second place, up 109% and Hess comes in third with a gain of 94%. Rounding up the top ten are Marathon Petroleum, Exxon, Schlumberger, APA, First Solar, Halliburton and Marathon oil, all up between about 70 and 80% this year.

Gas and oil prices have been falling in recent weeks, but they’re still higher than they have been over the past few years. That’s contributed to record-breaking profits at major energy companies. The net income of global oil and gas producers is expected to double in 2022 to a record $4 trillion, according to the International Energy Agency.

In the third quarter, 81% of all energy companies in the S&P 500 reported earnings above estimates, the highest of any sector, according to Factset data. The energy sector reported the highest year-over-year earnings growth of all 11 sectors, at 137.3%.

The losers

This was the year of no more free lunch in Silicon Valley.

Big Tech soared to new heights over the past decade as the companies enjoyed a low-interest rate, low inflation environment. That’s no longer the case, tech and communications stock prices clearly reflect that.

Energy technology solution company Generac Holdings is the worst performing stock in the S&P 500 so far this year, down about 74%. Coming in second is dating app company Match Group, which is down 70%. Elon Musk’s Tesla is also down about 70%, making the auto tech company the third worst performer this year. Meta, Facebook’s parent company, also makes an appearance in the bottom ten stocks– down 65%.

That’s a huge shake-up, at the start of this year Tesla was the fifth most valuable company in the S&P 500 and Meta was sixth.

Big tech had a nightmare year in 2022– collectively losing nearly $4 trillion in market value in 2022. That’s a lot when you consider the 10 worst-performing stocks in the S&P 500 have wiped out a market value of about $1.6 trillion.

Even Apple, generally considered more resilient than other tech companies, is down 31%, more than the overall market in 2022.

Wall Street is hoping for a tech rebound next year, but with more interest rate hikes on their way and a possible recession, investors may be left waiting.

The-CNN-Wire™ & © 2022 Cable News Network, Inc., a Warner Bros. Discovery Company. All rights reserved.