Tesla (TSLA -1.11%) is one of the more controversial stocks currently trading on the market. From devoted fans to dedicated critics, the company inspires a wide range of emotions, and that's understandable. At its current market cap of $716 billion, it's worth more than the next six international automakers combined. And the stock trades at a pricey 20.5 times sales.

However, I think many investors underestimate Tesla's full potential. Here are three reasons this stock is still a smart buy.

Red Tesla Roadster in motion as the sun rises.

Image source: Tesla.

1. First-mover's advantage

Tesla was not the first company to build an electric vehicle (EV) -- that happened back in the 1800s. But it was the first EV maker to achieve significant scale, and that advantage has made Tesla the front runner in a rapidly growing industry. Through the first half of 2021, Tesla sold 386,100 EVs, capturing an industry-leading 15.2% market share.

But there are broader implications here as well. Tesla was engineered from the ground up to build EVs; each Gigafactory and each piece of machinery was made for this purpose. By comparison, legacy automakers built their factories for internal combustion engines. And in order to transition away from that dying industry, those companies will have to invest billions to retool existing infrastructure.

Case in point: General Motors spent $2.2 billion to overhaul a single factory last year, and the company plans to spend $35 billion by 2025. Meanwhile, Tesla has well over 1 million EVs on the road today, and it's ramping production at an impressive pace.

2. Cost advantage

The most expensive part of an EV is the battery pack. To tackle that problem, Tesla partnered with Panasonic, and the pair developed the 2170 battery cell for the Model 3 in 2017. Compared to its predecessor, the 2170 can store 50% more energy. In fact, CEO Elon Musk called it "the highest energy density cell in the world, and also the cheapest."

As a result, Tesla's battery packs cost just $187 per kilowatt-hour, according to Cairn ERA. Put another way, Tesla pays 10% less per kilowatt-hour than the next closest competitor, which happens to be General Motors, and 24% less than the industry average. That means Tesla has a significant cost advantage -- and as production capacity has expanded, that advantage has become more evident.

Last year, Tesla produced just over 509,000 vehicles, nearly five times more than it pumped out in 2017. That helped the company deliver an industry-leading operating margin of 6.3% in 2020, and that figure climbed to 11% in the most recent quarter. But Tesla still has another trick up its sleeve.

Last September, the company announced its next battery cell: the 4680. Management believes this new cell will increase range by 54%, reduce the cost per kilowatt-hour by 56%, and cut capital expenditures by 69%. In short, the 4680 should reinforce Tesla's cost advantage when the new cell enters volume production in the next 12 to 18 months.

Artificial intelligence chip emitting blue light.

Image source: Getty Images.

3. Technology advantage

Since October 2016, all Teslas come with autopilot hardware, including an on-board supercomputer -- which was upgraded in 2019, and is estimated to be some six years ahead of its rivals' -- and eight external cameras. This allows Tesla to collect driving data from its fleet of over 1 million vehicles.

To that end, Tesla has far more data than its rivals. In 2020, the company reached 3 billion miles worth of real-world driving data, while Alphabet's Waymo and General Motors' Cruise reported just 20 million and 2 million, respectively.

Why does that matter? In order to build a self-driving car, two things are required: lots of data and a powerful computing platform. Tesla has the former in spades, and it addressed the latter at its recent AI Day, where it introduced the D1 processor. This AI chip will infuse its Dojo supercomputer with exascale processing power, making it the most powerful AI training machine in the world.

In short, Tesla is the clear leader in the race to build a self-driving car. In fact, Musk recently said the company would make a fully autonomous $25,000 EV in the next three years.

The big picture

If Tesla is just an EV company, its stock certainly isn't cheap at 20.5 times sales, despite its numerous competitive advantages. However, if you consider Tesla as an AI company that happens to make EVs, the narrative changes.

Once Tesla has a self-driving car, it plans to launch an autonomous ride-hailing service, creating an industry that Ark Invest values at $1.2 trillion by 2030. And given its leadership position, I think Tesla could capture the lion's share of that figure.

But an autonomous car would also open other doors. For instance, Tesla could license its full self-driving platform to other automakers, entering the high-margin software industry. Analysts at ARK Invest value this market at $250 billion by 2030.

In both cases, Tesla would benefit from recurring revenue and a massive market opportunity. And tech companies with those characteristics trade at much higher valuations than automakers. In other words, a decade from now, this stock might look relatively cheap in hindsight. That's why Tesla is still a smart buy.