Everyone wants a piece of SpaceX. But how can you invest in SpaceX stock?

Last year, Amazon.com (NASDAQ:AMZN) "competitive intelligence tools" subsidiary Alexa (yes, Alexa has a side job) reported on how SpaceX's website has become one of the most popular corporate websites among privately held companies. As measured by "unique visitors," more people are looking into SpaceX than any other "unicorn" stock on the planet.

It's no mystery why. After becoming the first private company to put a spaceship in orbit, Elon Musk's groundbreaking space venture has proceeded to rack up an impressive list of other "first" achievements: First company to launch a payload into orbit, then land its rocket back on Earth. First to land a Falcon 9 rocket on a landing pad at sea. First to re-launch a used rocket, and first to put forth a workable plan for colonizing Mars.

First, first, first.

Calculating the odds of a SpaceX IPO

But will SpaceX also become the first space company to conduct a big IPO in the 21st century and give investors a chance to invest in its stock directly? At last report, Musk was still reluctant. Speaking at a space conference in Guadalajara last year, Musk dismissed any interest in reaping billions by putting SpaceX on the stock market. To the contrary, the internet millionaire-turned-electric cars-billionaire said that it was actually his biggest fear that SpaceX might "somehow get taken over by investors who just want to maximize the profit of the company and not go to Mars."

That statement threw cold water on investors hoping to one day invest in SpaceX stock. And yet would you believe that it's possible to invest in SpaceX today -- before the company even IPO's?

Falcon 9 rocket on launch pad.

Investors see blue skies for SpaceX -- but how can you invest in SpaceX stock? Image source: SpaceX.

It's true. Thanks to Google's 2015 investment in SpaceX, Google parent Alphabet (NASDAQ:GOOG) (NASDAQ:GOOGL) now owns a 7.5% stake in SpaceX. As a result, it is now possible to invest in SpaceX -- by investing in its part-owner, Alphabet. (As a bonus, you also own a whole lot of Google, YouTube, the Android operating system, and a nascent self-driving car project besides.)

A better way to invest in SpaceX stock -- and also the only way

Buying Alphabet stock in order to own SpaceX stock might even be a smart financial move. Consider: Last year, we learned that after several years of boasting that it was both "profitable and cash-flow positive," SpaceX was actually neither of those things. Not profitable, and not generating cash -- but rather burning it.

That hardly sounds like the kind of stock investors should be thinking of trading.

SpaceX's resurgence in 2017 may have improved the company's financial fortunes, or it may not have. So far, SpaceX isn't telling. But just in case SpaceX is still losing money, it seems to me that diversifying one's investment in SpaceX by also owning wildly profitable Alphabet stock is a smart move to make.

Valued at $644.5 billion today, Alphabet reported net income of $19.3 billion over the past 12 months -- enough to give it a pretty reasonable P/E ratio of 25.6. (The average stock on the S&P 500 only costs about 24.6 times earnings, and with a 19.5% profit margin and an earnings growth rate of 20%, Alphabet is a far better than "average" company.)

Valued on its actual cash profits meanwhile (its free cash flow), Alphabet stock is even cheaper. According to data provided by S&P Global Market Intelligence, over the past year Alphabet has generated more than $25 billion in positive free cash flow -- about $1.30 in real cash profit for every $1 it's allowed to classify as "net income" on its income statement. And as cash has piled up on its balance sheet, the enterprise value of Alphabet stock has shrunk to the point where the whole company, net of cash, now costs less than $554 billion. Priced today at barely 22 times free cash flow, Alphabet stock is a whole lot cheaper than it looks.

It's a very cheap way to invest in SpaceX stock, and -- for the moment -- the only way.

Suzanne Frey, an executive at Alphabet, is a member of The Motley Fool's board of directors. Rich Smith owns shares of Alphabet (C shares). The Motley Fool owns shares of and recommends Alphabet (A shares), Alphabet (C shares), and Amazon. The Motley Fool has a disclosure policy.