The stock market has been a wild ride this year, with some stocks tanking because of the pandemic-induced recession, while others have skyrocketed because of their opportunities to tap into pandemic-proof businesses. 

But a volatile market has made it difficult for some investors to figure out which stocks are the best to invest in right now. If you're trying to decide between the entertainment powerhouse of Walt Disney (DIS -0.58%) and the e-commerce giant Amazon (AMZN -0.57%), then you've come to the right place.

Let's take a look at why both of these companies are attractive to investors and why Amazon is a better overall investment. 

Two people pointing at charts on a table.

Image source: Getty Images.

What Disney is doing right 

Before the pandemic, Disney appeared to be firing on all cylinders as its stock hit all-time highs. What got the company to that point is what still makes Disney's stock a compelling buy: A massive entertainment and media company that's only beginning to tap into its newest brands.

For example, Disney bought both Marvel and Lucasfilm for about $4 billion each, and the company is only at the starting line of making money from these massive entertainment franchises. Movies, television shows, theme park rides, toys, and licensing deals will fill Disney's top line for years to come from these two brands alone. 

Before the pandemic, Disney's array of theme parks brought in 156 million visitors last year. That's a staggering figure, and there's no reason why the company won't be able to get back to it eventually, once COVID-19 is a thing of the past. Even now, Disney has adapted to the pandemic and has brought back visitors at several theme parks around the world, albeit at limited park capacity. 

And then, of course, there's Disney's video streaming opportunity. Disney+ launched nearly a year ago and already has 60.5 million paying subscribers, a huge jump from the 33.5 million subscribers it had at the end of March. Disney+ has been a runaway success, and some of the company's latest moves indicate that Disney is shifting even further toward video streaming.

For example, Disney just restructured its business to focus more on video streaming and to help the company tap further into ad sales, and the move could help set up Disney for even faster growth from its entertainment and media businesses in the coming years. 

What Amazon is doing right 

Like Disney, Amazon has a lot of irons in the fire, and picking out just one for investors to focus on doesn't do the company justice. So let's start with Amazon's e-commerce business. The pandemic forced many people out of physical stores earlier this year, and as a result, Amazon's sales surged 43% in the second quarter and earnings per share hit $10.30, smashing earnings of $5.22 in the year-ago quarter.

Amazon was already doing well before in-person retail shopping dried up, but the pandemic has accelerated consumers' shift to online shopping. For example, two years ago, 10% of U.S. retail sales occurred online, but that percentage has spiked to 16% now. And there's little to prove that this trend will reverse once the pandemic is over. It's likely that the pandemic will be a catalyst that moves more people into e-commerce faster than before, rather than just a one-off event. 

This becomes even more evident when you consider that Amazon now has 150 million Prime members, an increase of 50% from just two years ago. Prime members spend more money on Amazon's website than the average Amazon customer, and the fact that Prime membership has grown so much in such a short time shows just how much value Amazon has created for its customers.

Investors should know that Amazon is also a leader in the cloud computing space, with 33% of the cloud infrastructure market. The company's Amazon Web Services (AWS) is not only a dominant force in the cloud space, it's also a big profit generator for the company. AWS sales totaled $10.8 billion in the second quarter, but accounted for $3.4 billion in operating income. That's far more than the $2.1 billion in operating income Amazon earned from its North American e-commerce sales of $55.4 billion in the same quarter. 

With Amazon already dominating e-commerce and cloud computing, the company is perfectly poised to continue growing in the coming year as it taps further into these markets. 

Why Amazon is a better buy right now 

While I think Disney is still a good long-term investment and even looks attractive with the company's shares down 12% year to date, Amazon is likely the better buy. Investors should consider that even during a pandemic and recession, not only have Amazon's sales and earnings grown, the company has also added hundreds of thousands of jobs. Meanwhile, Disney and many other companies have been forced to cut jobs.

Amazon is well-diversified in very different businesses, and ones that are seemingly recession-proof. With the company always looking for new ways to expand its services and find new markets to enter, there's little doubt that Amazon will continue to find new ways to continue growing for many more years to come.