Amazon (AMZN -1.09%) is a technology powerhouse. It was founded in 1994, and it amassed a $1.5 trillion valuation in the 30 years since.

The company originally sold books online, though its catalog has expanded to include an estimated 12 million products. In 2023, Amazon accounted for 37.6% of all e-commerce sales in America, which was light-years ahead of second-place Walmart at 6.3%.

But here's the thing. Online sales -- combined with all of its other businesses except one -- accounted for a minority of Amazon's operating income through the first three quarters of 2023 (ended Sept. 30). In 2022, they contributed no operating income at all.

Below, I'll tell you where Amazon generates the overwhelming majority of its profit, and it's a segment all investors should watch very closely in the future.

E-commerce remains Amazon's largest segment

Before we dive into Amazon's profitability, let's look at where its revenue comes from. While the company is still very much focused on its e-commerce business, it expanded significantly over the years to operate in cloud computing, digital advertising, robotics, and streaming.

Amazon generated $143.1 billion in total revenue during the latest third quarter, and here's where it came from:

Segment

Q3 Revenue (Billions)

Percentage of Total Revenue

Online stores

$57.3

40%

Third-party seller services

$34.3

24%

Amazon Web Services

$23

16.1%

Advertising services

$12.1

8.5%

Subscription services

$10.2

7.1%

Physical stores

$4.9

3.5%

Other

$1.2

0.8%

Data source: Amazon.

As you can see, online sales were still Amazon's largest source of revenue. Commissions and fees charged to third-party sellers on Amazon's platform were the second-largest contributor.

Advertising services are becoming increasingly important as Amazon finds new ways to sell digital ad spots to businesses on its website and through its streaming platforms like Prime and Twitch. In Q3, advertising services revenue grew by 25% year over year, the fastest pace of any segment.

But the most important business of all might be Amazon Web Services (AWS). It's the largest cloud computing platform in the world, delivering hundreds of digital solutions to businesses. It helps them store data, host their digital sales channels, develop software, and now, build artificial intelligence (AI) applications. The latter could be Amazon's greatest financial opportunity ever.

The majority of Amazon's operating income comes from AWS

For reporting purposes, Amazon breaks its operations into two categories: net product sales and net service sales. But that doesn't really tell us where its profits are coming from specifically. Therefore, the company provides a more granular look at its financials by splitting them into three categories: North American sales, international sales, and AWS.

As discussed earlier, Amazon has seven main business segments. North American and international sales aggregate the financial results from six of them, with AWS' financials reported separately. There's a good reason for that.

In the first three quarters of 2023, AWS delivered operating income of $17.4 billion. By comparison, North American and international sales combined generated operating income of just $6.1 billion.

Remember, AWS revenue only accounts for 16.1% of Amazon's total revenue, yet it was responsible for a whopping 74% of the entire company's operating income.

A pie chart of Amazon's operating income, showing that Amazon Web Services accounts for 74%.

Cloud computing carries a high operating margin because selling digital services is a scalable business model. One data center can serve the needs of thousands of businesses all over the world, which rent its computing power to run their digital operations. In Q3, AWS delivered an operating margin of 30.3%, whereas the combined operating margin from North American and international sales was just 1.8%.

In order for Amazon to charge low prices for products in its e-commerce segment, it has to operate on a razor-thin profit margin. Given that's the company's largest source of revenue, it sometimes drags down the financial results of smaller divisions even if they might be profitable on their own.

In 2022, North American and international sales delivered an operating loss of $10.6 billion, so AWS was responsible for 100% of Amazon's operating income for the year.

Amazon stock is incredibly cheap by one valuation metric

AWS -- and specifically its growing presence in artificial intelligence -- has become a big reason investors want to own Amazon stock. The platform now offers its own AI data center chips to compete with Nvidia, and it has also developed a series of large language models in-house. It means businesses can access all the hardware and software they need to build AI applications on AWS.

Plus, Amazon recently invested $4 billion in leading AI start-up Anthropic. It will use AWS as its primary cloud provider, and it will train its future models using Amazon's data center chips, which could entice other developers to try out the hardware, especially since Nvidia faces supply constraints.

Amazon will report its official 2023 full-year financial results in early February, but its total revenue is expected to come in at $517 billion. Considering Amazon's current valuation of $1.5 trillion, that places its stock at a price-to-sales (P/S) ratio of just 2.7.

That's dirt cheap compared to Microsoft stock, which trades at a P/S ratio of 12.7. That company is home to the world's second-largest cloud platform, Azure, which also has a growing focus on AI. Microsoft deserves a premium because it's more profitable on the whole, although Amazon generates more than double the amount of revenue. I don't think Amazon's P/S ratio deserves to trade at such a steep 79% discount to Microsoft's.

In fact, Amazon is the cheapest of all the "Magnificent Seven" technology giants based on the P/S metric.

NVDA PS Ratio Chart

Data by YCharts

Personally, I think that valuation gap could begin to close in 2024 as AWS ramps up its efforts in AI, which could pave the way for upside in Amazon stock.

Depending which Wall Street forecast you rely upon, that technology could add between $7 trillion and $200 trillion to the global economy in the next decade. So, it's likely AWS will continue to make up the lion's share of Amazon's operating income, and it could become even more critical to the company overall.