The stock market has been on a tear following its massive plunge in March. The S&P 500 has jumped 20% over the past 12 months, and some of that growth is thanks to tech stocks that are performing well despite the pandemic and the U.S. recession. 

Many technology companies have grown during the pandemic, as their services have become more in demand with the increase of stay-at-home workers. For investors who are looking for tech stocks to add to their portfolios, here's why Fastly (FSLY -0.87%) and Microsoft (MSFT -0.66%) should make the cut. The first is a great bet if you're looking for a growth stock, and the latter provides investment stability during uncertain times.

A man looking at two computer screens.

Image source: Getty Images.

Fastly's furious growth 

Fastly's services help apps and websites accelerate their content so they run faster and better. One of Fastly's customers is Slack, which uses Fastly to help deliver its messaging and workplace collaboration tools to its millions of users. 

As more people are spending more time at home, companies have looked to Fastly to provide fast, reliable internet-based services and that's accelerated Fastly's growth. Sales spiked 62% in the second quarter to $74.7 million, and the company's earnings per share of $0.02 were a huge improvement from a loss of $0.16 in the year-ago quarter. Fastly also proved that the company can grow its customer base amid an economic downturn and added 114 new customers in the quarter, a 6% increase.

Not only did Fastly have a fantastic quarter, but management increased their outlook for the company's full-year revenue, from a previous range of $280 million to $290 million to the current range of $290 million to $300 million.

The optimism about Fastly's future hasn't been contained to just the company's management -- investors have pushed Fastly's share price up 343% since the beginning of this year. But don't think that the company's growth days are behind it. Providing faster content delivery was already a big selling point for Fastly's services before the pandemic, and it's even more so now. 

A darkened dark server room

Image source: Getty Images.

A reinvented tech stalwart

If you're looking for a technology stock that can help you weather the current recession and boost your portfolio, Microsoft looks like a good bet. 

Microsoft impressed investors when it reported 13% revenue growth in the company's fiscal fourth quarter, which ended on June 30, and sales from its "more personal computing" segment increased 14% year over year. 

Most importantly, Microsoft continued to grow its Azure cloud computing business in the quarter, with sales from the segment jumping 47%. Cloud computing infrastructure has become an important service for companies of all sizes that need a cloud platform to develop websites, apps, and other services. The cloud computing infrastructure market is projected to grow from $73 billion in 2019 to an estimated $167 billion by 2024, and the good news for Microsoft investors is that the company already has 18% of this market, trailing only Amazon in the space.

Microsoft was once synonymous with Office and Windows, but over the past few years, the company has reinvented itself into a cloud computing powerhouse. When you combine the company's position in the cloud with its stability as a long-standing tech leader, you get an investment opportunity that will not only weather the current economic storm, but also benefit from emerging tech markets.