Despite the recent sell-off, the stock market is an excellent way to build wealth over long periods. In fact, the S&P 500 has produced a total return of 436% over the last 20 years, equivalent to an annualized return of roughly 8.7%. At that rate, $375 invested weekly would be worth over $1 million two decades from today. That means you can build a million-dollar portfolio with nothing more than an index fund and a long-term mindset.

However, if you're willing to do some research, a handpicked portfolio of individual stocks could make you even richer. For instance, MercadoLibre (MELI -1.76%) and The Trade Desk (TTD 3.52%) operate in quickly growing industries, and both benefit from a strong competitive position. For that reason, I think shareholders could see 10x returns over the next decade.

Here's why.

A couple sits on the couch with their computer, making an online purchase.

Image source: Getty Images.

1. MercadoLibre

MercadoLibre operates the largest e-commerce and fintech ecosystem in Latin America. Its online marketplace sees more page views and unique visitors than any competing platform, supercharging the network effect that powers its business. Specifically, merchants naturally gravitate toward the most popular marketplace, looking to reach as many consumers as possible. As that happens, MercadoLibre's product catalog becomes bigger and broader, which brings more consumers to the marketplace and starts the cycle again from the beginning.

To strengthen its position, MercadoLibre offers several value-added services, including logistics support, digital advertising tools, and access to credit. But none of those products have been as impactful as its fintech platform Mercado Pago. Mercado Pago has become tremendously popular both on and off the marketplace by democratizing digital payments in a region characterized by low bank account and debit card penetration. In fact, total payment volume jumped 55% to $77.4 billion in 2021, and the number of off-platform merchants doubled.

Together, MercadoLibre's leadership position and robust product portfolio have translated into monster financial results. Last year, revenue skyrocketed 78% to $7.1 billion, and the company posted a profit of $1.69 per diluted share, up from a loss of $0.07 per diluted share in 2020.

Looking ahead, online retail sales in Latin America are expected to grow at 18% annually to reach $138 billion by 2024, according to Statista. Similarly, digital wallets will become increasingly popular over the same period, accounting for 31% of online payments and 12% of in-store payments by 2024, up from 20% and 6%, respectively, in 2020.

In both cases, those tailwinds should work to MercadoLibre's advantage. In fact, as the largest e-commerce and fintech ecosystem in the region, I think this $45 billion business could grow tenfold in the next 10 years, reaching a market cap of $450 billion (or more) by 2032.

2. The Trade Desk

The Trade Desk specializes in digital advertising. Its platform leans on artificial intelligence to help marketers purchase ad impressions programmatically, meaning the process is automated through real-time bidding. Whereas traditional media buying was done in advance (through manual negotiations), programmatic technology allows clients to make data-driven decisions right before the ad is displayed. To that end, marketers can launch, measure, and optimize targeted campaigns across digital channels such as computers, mobile devices, and connected TVs (CTVs).

Of particular note, The Trade Desk is the largest independent platform for ad buyers, which has two important implications. First, "independent" means The Trade Desk isn't affiliated with any content, so it doesn't have an incentive to push ad buyers toward any particular website or mobile app. And that differentiates the company from rivals like Alphabet and Meta Platforms.

Additionally, The Trade Desk has significant scale -- its platform sees 13 million ad opportunities each second -- meaning it captures lots of consumer data regarding tastes and preferences, which makes its AI models better at targeting content over time.

Those selling points have collectively helped The Trade Desk keep customer retention over 95% for the last eight years, which has fueled strong financial growth. In 2021, revenue climbed 43% to $1.2 billion, and non-GAAP earnings jumped 32% to $0.91 per diluted share. Better yet, I think this company is just getting started.

In 2021, The Trade Desk formed several meaningful partnerships. That includes Walmart in the shopper marketing space, Samsung and Comcast's Peacock in the CTV space, and Xiaomi (the world's second-largest smartphone maker) in the mobile space. Those moves expand its access to ad inventory, making its platform more valuable to marketers.

More broadly, global digital ad spend hit $492 billion in 2021, according to eMarketer, but The Trade Desk captured just $6.2 billion (less than 2%) of that total, meaning there is plenty of room for growth. For that reason, I think this $27.5 billion business could be worth $275 billion in 10 years.