Contrary to conventional wisdom, cash is not king. But cash flow is. At least that's the case in investing. Stock valuations are driven primarily by expectations of future cash flows.

Investors, therefore, should look closely at the ability of companies to generate significant cash flow -- and what the companies do with that cash flow. With that in mind, here are three stocks to buy for 2022 that are practically money machines.

2022 on top of $100 bills coming out of a printing press..

Image source: Getty Images.

1. Alphabet

Alphabet (GOOG 0.81%) (GOOGL 0.72%) generated almost $66 billion in free cash flow over the past 12 months. Unsurprisingly, the stock was a big winner in 2021, vaulting nearly 70% higher.

Can the tech giant continue to essentially print money? I think so. History is certainly on Alphabet's side: Its free cash flow has increased by 188% over the past three years. 

The company's search apps, notably Google Search and YouTube, rake in billions of dollars of revenue every quarter. Alphabet has other moneymaking assets, though, including the Android operating system and Google Cloud.

Investors should also like how Alphabet puts its cash flow to work. The company bought back $1.5 billion of its Class A shares and $11.1 billion of its Class C shares in the third quarter of 2021. It's also investing in initiatives that could fuel future growth such as self-driving car technology business Waymo and drone-based delivery provider Wing. 

2. Devon Energy

Devon Energy (DVN 1.51%) didn't singlehandedly drive the S&P 500 index to a record high in 2021. But it deserves a lot of the credit. Shares of the oil and gas producer skyrocketed more than 175% last year.

The company's free cash flow in the third quarter of 2021 topped $1.1 billion. That might not seem overly impressive at first glance. However, it's a drastic improvement from the previous year -- jumping eighfold since the fourth quarter of 2020. And Devon expects its free cash flow to increase at least another 40% in 2022.

What's especially attractive about Devon's free cash flow is what the company does with it. Devon uses up to 50% of its excess free cash flow to fund a variable dividend. The combination of the company's fixed and variable dividend gives it a yield of more than 9%. That's more than seven times higher than the S&P 500's dividend yield. 

In addition, Devon plans to buy back $1 billion in shares by the end of 2022. This should be a good investment. The stock's enterprise value (EV) is only 3.8 times Devon's expected 2022 earnings before interest, taxes, depreciation, and amortization (EBITDA). By comparison, the S&P 500's forward EV/EBITDA multiple is 14.5. 

3. Pfizer

Pfizer (PFE 0.85%) is a bona fide pharmaceutical cash cow these days. The drugmaker generated free cash flow of more than $29 billion over the last 12 months. Its free cash flow has more than doubled over the past three years. And the big pharma stock was a huge winner in 2021, soaring around 60%.

It's not hard to guess what's primarily behind this growth. Pfizer's COVID-19 vaccine Comirnaty, developed with BioNTech, has been a massive commercial success. The two companies project that Comirnaty raked in $36 billion in 2021. 

Pfizer should make a lot more money in 2022. In addition to continued strong sales for Comirnaty, the company's COVID-19 pill Paxlovid is likely to pull in $24 billion or so this year. Of course, Pfizer also has multiple other blockbusters, including its blood thinner Eliquis, cancer drugs Ibrance and Xtandi, and Prevnar pneumococcal vaccines. 

What's Pfizer doing with its growing cash flow? The dividend is a top priority. The drugmaker's dividend yield currently stands at close to 2.8%. Pfizer is also gobbling up smaller companies with the acquisitions of Arena Pharmaceuticals and Trillium Therapeutics.