Predicting how the market will behave in the next few months is impossible, especially considering the economy still faces severe issues such as inflation. However, in 10 years or more, the market will be up. Even serious downturns seem far less scary when you look at a chart of the performance of the broader market over several decades.

That's why looking for stocks that can survive the test of time can pay hefty dividends down the road. In that spirit, let's examine two healthcare stocks that seem to have the tools to provide solid returns over the long term: Eli Lilly (LLY -1.81%) and Teladoc Health (TDOC -0.07%).

LLY Chart

LLY data by YCharts

1. Eli Lilly

The best way for drugmakers to remain relevant over the long run is to continue developing innovative therapies, either for illnesses for which there is plenty of competition, or for those for which there is a dire need. Eli Lilly seems to excel in both areas. Take one of the company's most recent approvals: Mounjaro, a therapy used to control blood glucose levels in patients with type 2 diabetes.

Eli Lilly has been competing with two other major players, Novo Nordisk and Sanofi, in the diabetes drug market for several decades. However, Mounjaro proved more effective than Novo Nordisk's semaglutide in a phase 3 clinical trial. So far, the medicine seems to be having a successful launch after getting approved in the U.S. back in May.

As Eli Lilly's CFO, Anat Ashkenazi, said during the company's second-quarter earnings conference call: "We are pleased with the initial uptake of Mounjaro, which is at the high end of our contemplated scenarios." Mounjaro could earn a label expansion as a weight loss therapy, too. This medicine looks set to deliver more than $1 billion in annual sales at its peak.

Elsewhere, Eli Lilly is developing donanemab, a potential therapy for Alzheimer's disease -- an area in which there is plenty of work to be done. The medicine received the Breakthrough Therapy designation from the U.S. Food and Drug Administration, which aims to speed up the development and approval of potential treatments that target serious illnesses

Still, It's too early to tell whether donanemab will earn approval. But Eli Lilly's wise investment in research and development and its ability to expand its lineup is a potent weapon that can help it succeed in the long run.

Spending on prescription drugs will continue to increase as the world's population ages. The number of patients in Eli Lilly's area of expertise -- diabetes -- will also grow in the coming decades. In short, the long-term thesis for Eli Lilly remains solid. 

2. Teladoc Health

Telemedicine specialist Teladoc isn't as well-established as Eli Lilly. What's more, the company has struggled lately due to deepening net losses; the red ink on its bottom line is the main reason behind its poor performance in the market this year. There is also the worry that major corporations like Amazon could enter the telehealth market and steal substantial market share away from Teladoc.

But in my view, all of these worries, although real, are a bit overblown. Teladoc's net losses have been due primarily to non-cash goodwill impairment charges related to its 2020 acquisition of Livongo Health. It seems Teladoc did overpay for the acquisition, but that says little about the company's day-to-day operations.

And while it might face tougher competition in telehealth, this industry got a boost during the pandemic, and the uptake in telemedicine activity in the past two years is set to last. Between 2019 and 2020, virtual healthcare visits grew from 14,000 to 3.1 million. And according to estimates, 83% of patients will continue to use virtual care visits after the pandemic.

Multiple companies can be winners in this lucrative and growing space, and Teladoc has an edge thanks to its first-mover advantage. The company has already built a network of more than 50,000 healthcare experts worldwide who offer more than 450 specialties. This vast ecosystem is attractive to both individual patients and third-party payers.

Also, it arguably grants Teladoc a network effect: The value of its platform improves as more people use it. The more physicians join the platform, the more it becomes attractive to patients, and vice versa. It will be hard to pull these customers away from Teladoc -- in fact, the company continues to grow in this area.

During the second quarter, the company's total U.S. paying members increased by 9% year over year to 56.6 million. Total visits increased by 28% year over year to 4.7 million. The company's revenue for the quarter came in at $592.4 million, 18% higher than the year-ago period. These metrics should continue to improve, and in the long run, Teladoc is well-positioned to remain a leader in telemedicine.

With the company's stock down by 65% year to date, now is an excellent time to initiate a position.