Palantir's (PLTR -3.12%) stock price tumbled 9% on Tuesday after the data-mining firm posted its third-quarter earnings. The pullback was a bit surprising since its growth rates looked healthy and it offered rosy guidance for the full year.

Let's dig deeper into Palantir's third-quarter report, and review three compelling reasons to buy the stock -- as well as one reason to sell it.

Palantir's banner at the New York Stock Exchange.

Image source: Palantir.

1. Its commercial growth is accelerating

Palantir's revenue rose 36% year over year to $392 million, which beat analysts' expectations by about $5.5 million.

Palantir generated 56% of its quarterly revenue from government contracts and the remaining 44% from commercial contracts. When Palantir went public last September, the bears claimed it would struggle to expand its commercial business to reduce its dependence on government contracts.

However, Palantir's commercial growth actually accelerated throughout 2021 and grew faster than its government business in the third quarter:

Revenue Growth (YOY)

FY 2019

FY 2020

Q1 2021

Q2 2021

Q3 2021

Government

35%

77%

76%

66%

34%

Commercial

17%

22%

19%

28%

37%

Total

25%

47%

49%

49%

36%

Source: Palantir. YOY = Year over year.

Palantir attributed that acceleration to the growth of its U.S. commercial business, which more than doubled its revenue year over year.

Its commercial customer count rose 46% sequentially and more than doubled since the beginning of the year. Its average revenue per top-20 customer also increased 35% year over year. Those growth rates suggest that Palantir's hardened reputation as a data mining platform for the U.S. government is attracting a lot of attention from enterprise customers.

Palantir's government business also continued to grow against tough year-over-year comparisons, as it secured new contracts with the U.S. Air Force, the U.S. Department of Health and Human Services, and the NIH.

Palantir expects its revenue to rise 40% to $1.53 billion for the full year. It also maintained its long-term guidance for more than 30% annual revenue growth from 2021 to 2025.

2. Stable gross and operating margins

Palantir is still unprofitable on a generally accepted accounting practices (GAAP) basis. It posted a net loss of $102.1 million during the third quarter, compared to its loss of $853.3 million a year ago (which bore the impact of the high stock-based compensation expenses related to its direct listing).

However, its adjusted (non-GAAP) gross and operating margins, which exclude its stock-based compensation and other one-time expenses, expanded year over year and remained stable quarter over quarter:

Period

Q3 2020

Q2 2021

Q3 2021

Adjusted Gross Margin

81%

82%

82%

Adjusted Operating Margin

25%

31%

30%

Source: Palantir.

As a result, Palantir's non-GAAP net income rose 51% year over year to $82.1 million, or $0.04 per share, which matched analysts' expectations.

That profit growth indicates Palantir still has plenty of pricing power, and its operating margins are improving as it scales up its main platforms.

3. Free cash flow growth

Palantir's strong growth in revenue and adjusted profits turned its adjusted free cash flow (FCF) positive this year.

Period

First 9 months of 2020

First 9 months of 2021

Adjusted free cash flow

($285 million)

$320 million

Source: Palantir.

In its third-quarter report, it boosted its full-year adjusted FCF guidance by about $100 million to more than $400 million.

The reason to sell Palantir: Its high valuations

Palantir is growing rapidly, but its stock still trades at over 30 times this year's sales. That high price-to-sales ratio could limit its near-term gains.

Palantir's excessive use of stock-based compensation also caused its weighted-average shares to more than double year over year in the third quarter. As a result, its non-GAAP earnings per share (EPS) remained flat from a year ago even as its adjusted net income increased 51%.

That ongoing dilution is common for unprofitable high-growth companies, but it could also prevent Palantir's valuations from cooling off. Its frequent usage of non-GAAP metrics also masks the fact that nearly two decades after its inception, Palantir still lacks a viable path toward GAAP profitability.

Is Palantir worth buying?

Investors should realize that Palantir is a risky and volatile stock. That said, I still believe its strengths outweigh its weaknesses.

Palantir's valuation is high, but it isn't outrageous in a market that values Cloudflare (NET -3.01%) at nearly 100 times this year's sales and CrowdStrike (CRWD -3.90%) at almost 50 times this year's sales. For reference, Wall Street expects Cloudflare and CrowdStrike's revenues to increase 49% and 61%, respectively, this year.

Palantir isn't growing as rapidly as those two cloud-based companies, but it's equally disruptive. Just as Cloudflare is changing how companies secure their websites and deliver digital media, and how CrowdStrike is disrupting the cybersecurity market with cloud-native services, Palantir is changing how government agencies and large companies collect and analyze data from disparate sources to make data-driven decisions.

In short, Palantir remains a compelling long-term play for investors who can stomach the near-term volatility. If it achieves its goal of generating more than $4.3 billion in revenue by 2025, its stock could easily triple or generate even bigger multibagger gains over the next few years.