For investors who like big, fat net profits, connected-TV platform company Roku (ROKU -10.29%) is a stock to steer clear of. After posting its first full-year net profit in 2021, the company followed it up in 2022 with a record loss of $531 million.

In 2023, Roku beat this record with a new record loss of $710 million. For shareholders, it's a disheartening chart to look at for sure.

ROKU Net Income (Annual) Chart

Data by YCharts.

Of course, looking at Roku's net loss in isolation won't lead to anything actionable for investors. They must understand why the company is losing so much money, which may be a good enough reason for some to sell the stock. At the same time, there's more to this story, and Roku could also look like an attractive buying opportunity for more optimistic investors.

One reason to sell Roku stock

Roku generates revenue in two ways: It sells low-margin connected-TV hardware (device revenue), but it also provides high-margin connected-TV operating system software (platform revenue). The software side of the business has increasingly made up a larger part of the business, a key component of a bullish Roku investment thesis. However, Roku's margins are dropping instead of going up as one would have expected.

ROKU Revenue (TTM) Chart

Data by YCharts.

The explanation for the drop is quickly evident. Rewinding the clock to 2019, Roku's device revenue accounted for 34% of total revenue and had a gross margin of 4%. By comparison, its platform revenue had a gross margin of almost 65%.

In 2023, both of these numbers were far lower for Roku. The company's platform revenue now makes up 86% of the total, which is good, but its gross margin fell to just 48%. Meanwhile, device revenue had a negative gross margin of 9%. Both segments have taken significant steps in the wrong direction.

Roku has grown over the last several years (more on that in a moment), but by lowering its hardware prices as much as it has, it's sacrificing profitability. Moreover, some fixed costs have increased on the platform side of the business while advertising rates are down, contributing to its record losses.

Therefore, Roku's gross profit has lagged revenue growth. Additionally, the company has failed to gain operating leverage with scale. In fact, its operating expenses have gone up at a far faster pace than its revenue, which is the opposite of what investors want to see -- and it's a good enough reason for many to sell the stock.

ROKU Revenue (TTM) Chart

Data by YCharts.

One reason to buy Roku stock anyway

While Roku is losing a ton of money on streaming hardware, the move is paying off for the company. In 2023, the company added 10 million new active accounts and reached 80 million total -- its second-best year for user growth.

With its large user base, Roku is the top player in the streaming-TV space. And these aren't just casual users -- they're streaming more video content than ever before. Roku devices served up over 106 billion hours of streaming content in 2023, a 21% jump from the previous year.

For advertisers, Roku's audience is simply too big and important to pass up. Granted, the company's average revenue per user fell 4% year over year in the fourth quarter of 2023, suggesting advertisers are cutting back -- and that's concerning.

But as a general rule, advertisers go to where the audience is. Therefore, it's reasonable to think the current headwind for Roku is only temporary.

Assuming the connected TV space continues to grow, Roku stays a top player, and advertising demand recovers in future quarters and years, then this stock could handily beat the market from where it trades today. And that's one reason to take hold of the current opportunity and buy shares hand over fist.

The middle ground?

Personally, I see merit to both sides of this discussion. Roku's plunging losses are concerning and suggest deeper problems. But it does have a rapidly growing audience despite the headwinds, which bodes well for the future.

Therefore, I take the middle road here. I'm continuing to hold my shares of Roku stock today because there are good things happening with the business. That said, its record losses could mean its business is getting weaker due to competition, which is why I'm not actively adding to my position at present.