Like a movie with a twist ending, Roku (NASDAQ:ROKU) surprised its audience by posting a net profit in its latest quarter.

On Thursday, the company released its results for the third quarter of fiscal 2020, showing that its revenue rose by 73% on a year-over-year basis to $451.7 million. On the bottom line, Roku flipped dramatically to a $12.9 million profit, or $0.09 per share, from the Q3 2019 deficit of almost $25.2 million.

A family sitting on a couch and watching TV.

Image source: Getty Images.

The average analyst estimate for the quarter's revenue was only $367.8 million. Those prognosticators also anticipated a fairly deep per-share net loss of $0.40.

Much of Roku's improvement was due to the 78% growth in its all-important platform revenue, meaning the money it derives from having its operating system on third-party TVs and the advertising it sells. The company's growth in active accounts also helped, with the metric rising by 43% to hit 46 million in the quarter.

Meanwhile, the foundational Roku Channel continues to enlarge its footprint in the U.S., reaching a potential viewership of 54 million people in Q3. The company continues to add content to that channel, thus widening one of its revenue streams.

Cautioning that the "short-term macro environment remains both variable and uncertain" for its business, Roku provided little guidance for its current Q4. The company believes that its revenue growth for the quarter will be at the mid-40% level, in line with recent holiday seasons.

It forecasts that it will break even on gross margins for its hardware (the Roku streaming player line). Gross margins for platform profitability are expected to fall in the mid-50% to 60% range.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.