CVS Health (CVS -0.62%) is one of the largest healthcare companies in the world. It has expanded through multiple acquisitions, including by adding health insurance company Aetna. And even now, CVS is continuing to look for new opportunities to grow even bigger.

Below, I'll look at whether investing $10,000 in the healthcare stock a decade ago would have been a good move for investors and whether it's worth buying right now.

10 years ago, CVS was generating over $100 billion in revenue

Over the past decade, CVS' business has changed significantly. It was coming off a good year in 2011 when net revenue of $107 billion had grown by 12% from the previous year. However, modest gross margins of 20% meant that there was little impact to the bottom line and that profits were flat.

Since then, the business has taken on multiple acquisitions, with the most notable being Aetna in 2018 in a mammoth $69 billion merger. And with the exception of a goodwill impairment charge in 2018 that sent its bottom line briefly into the red, the overall trajectory for CVS has been positive over the past 10 years:

CVS Revenue (Annual) Chart

CVS revenue (annual). Data by YCharts.

Today, the company is pursuing more growth opportunities, including potentially getting into primary care and acquiring home health company Signify Health. But despite its appetite for growth and strong financials, that hasn't led to a big payday for CVS investors.

Here's how much the stock has grown

In August 2012, CVS' stock was trading at around $45 per share. The company hasn't split its shares since then, and so at today's price of roughly $100, it has risen by 122%. That means a $10,000 investment would now be worth more than $22,200. That averages out to a compound annual growth rate of 8.3%, which is less than the S&P 500's long-run average of 10%.

These returns don't factor in CVS' dividend payment, which yields 2.1%. But even when looking at total returns (which include dividends), a $10,000 investment in the S&P 500 would be worth more than $35,000 today versus $28,000 if you had invested in CVS. Although investors have made a decent return during those years, it's hard to say that investing in CVS has paid off. 

CVS Total Return Level Chart

CVS total return level. Data by YCharts.

Is CVS a buy today?

CVS is a much larger and more diverse company than it was a decade ago. It does have value today, at a time when the markets are in turmoil; year to date, its shares are down a modest 1% while the S&P has fallen by 13%. At a forward price-to-earnings multiple of 12, it's also a relatively cheap buy when compared to the Health Care Select Sector SPDR Fund, where the average stock trades at 16 times its future profits. 

There's some value for risk-averse investors, and CVS could make for a good, safe investment you can just buy and hold. But if you're investing for the long term, you might be better off sticking with the S&P 500 since there isn't a compelling reason to believe that CVS will outperform the markets.