The Nasdaq Composite just finished its best first half in four decades, soaring 32% on a particularly strong performance by technology stocks. That upward momentum helped Amazon and Nvidia join the elite group of companies whose valuations exceed $1 trillion, a group that already counted Apple, Alphabet, and Microsoft among its members.

But the global economy will continue to grow, and more companies will reach that milestone in the coming years. In fact, Tesla (TSLA -5.55%) is already closing in on a $1 trillion valuation, making it plausible that the company hits that mark in 2024. Meanwhile, Visa (V -1.19%) has a great shot at becoming a $1 trillion company by 2033.

Here's what investors should know.

Prediction: Tesla will be a $1 trillion company by 2024

Tesla reported mixed results in the first quarter. Revenue increased 24% to $23.3 billion, but net income declined 23% to $0.73 per diluted share as higher material costs and price reductions hit the bottom line. Yet, Tesla still led the industry in electric vehicle sales in Q1, capturing 23.6% market share, up from 21.6% in the prior year. Those gains put the company in a good spot. Global electric vehicle sales are expected to increase by 24% annually to reach $1.1 trillion by 2030, according to Precedence Research.

However, management sees full self-driving (FSD) technology as the most important growth driver. The global autonomous vehicle market is expected to increase at 39% annually to reach $1.8 billion by 2030, and Tesla is well-positioned to benefit. With more autonomous driving data than any other automaker, the company has an advantage in developing its FSD software because data is crucial to training artificial intelligence models. Additionally, every new Tesla is outfitted with what CEO Elon Musk calls the "most efficient inference computer in the world."

Here's the case for a $1 trillion market cap by 2024: Tesla is currently worth $890 billion, and its shares trade at 11.3 times sales. If revenue increases 20% in the next year -- a conservative estimate given that sales rose 38% in the last 12 months -- Tesla could achieve a valuation of $1 trillion by mid-2024 while its price-to-sales multiple falls to 9.7. That scenario is made more likely by the commencement of Cybertruck deliveries this year and plans to mass produce a robotaxi next year, both of which could add momentum to the stock price.

That said, investors would do well to widen their time horizon. Tesla could just as easily decline in value in the next year, but the company has a massive opportunity in electric and autonomous vehicles that could propel its market cap much higher in the future. In fact, Musk is convinced that Tesla will eventually be "the most valuable company on Earth," and Ark Invest recently published a valuation model suggesting Tesla could be worth $7.9 trillion by 2027.

Prediction: Visa will be a $1 trillion company by 2033

Visa reported strong financial results in Q2. Revenue climbed 11% to $8 billion, driven by double-digit growth in payment volume and processed transactions, and net earnings jumped 20% to $2.03 per diluted share. The company should be able to maintain a similar growth trajectory in the coming decade, and doing so could carry its market capitalization to $1 trillion (or beyond).

Visa operates the largest electronic-payments network in the world, as measured by acceptance locations and purchase-transaction volume, and from that scale arises a powerful network effect and a significant cost advantage that protects the business. Case in point: Visa's ubiquity means acceptance is essentially mandatory for merchants, and its operating margin consistently tops that of its closest competitor Mastercard by 8 to 10 percentage points.

Here's the case for a $1 trillion valuation by 2033: Visa is currently worth $510 billion, and the stock trades at 16.6 time sales. But if revenue increases by 10% annually over the next decade -- a reasonable estimate given that sales grew at 10.8% annually over the last decade -- Visa could be worth $1 trillion by 2033 at a more reasonable multiple of 12.4 times sales. But management sees a much longer runway for growth.

At Visa's 2020 Investor Day, CEO Al Kelly outlined a $226 trillion addressable market that could drive tenfold growth over the next two decades. That implies a market cap of $4.4 trillion by 2040, which itself implies annualized returns of 13% between now and then. That's a compelling reason to buy this growth stock.