Image source: PayPal.

What PayPal (PYPL 0.34%) did for small businesses online, Square (SQ -2.28%) is doing for small businesses in their physical stores. Both have grown to become leaders in their respective payment processing businesses, and they don't just serve small businesses anymore.

Both companies reported better-than-expected third-quarter earnings results that sent their stock prices higher. So far in 2016, shares of PayPal are up 14%, while Square's stock price is down 8%.

PYPL Chart

Image source: Ycharts.

Should investors buy shares of PayPal near its all-time high, or would it be better to invest in Square?

Different life stages

PayPal is a relatively mature business focused on growing its cash flows, while Square is still focused on growing its top line. That's not to say Square is ignoring its cash position. "Our strategy on cash is always to keep making it, so we will keep doing that," CFO Sarah Friar joked on Square's third-quarter earnings call.

Still, Square's focus is first and foremost on revenue growth. "We target much more a top-line growth number," Friar said later in the call. To be sure, top-line growth is strong. Last quarter, Square grew revenue 32% despite a tailing off of revenue from its partnership with Starbucks. Through the first nine months of 2016, revenue is up 41%. Comparatively, PayPal grew revenue 18% and 17% for the third quarter and the first nine months of 2016, respectively.

PayPal's focus on free cash flow, however, has its free cash flow growing in line with revenue growth. Last quarter, free cash flow reached $618 million. That's up 19% year over year. Through the first nine months of 2016, free cash flow increased 36%. (The huge jump is the result of spinoff expenses last year.)

By comparison, Square's free cash flow was just $22.5 million last quarter. That's a major improvement, however, from the negative $27.6 million in free cash flow in the third quarter last year.

A look at valuation

With PayPal focused on cash flow generation and Square focused on revenue growth, it's important to look at how the market is valuing each of the companies on those metrics. Those are the metrics management wants analysts to look at, after all.

PayPal shares are currently priced around 22 times trailing free cash flow. Keep in mind that the free cash flow number includes one-time expenses related to its spinoff. Comparatively, Square is valued around 5 times higher, at 100 times its minuscule trailing-12-month free cash flow. Of course, Square should be able to grow free cash flow at a much faster rate from its considerably smaller base.

On a price-to-sales basis, however, Square is less pricey than PayPal. Square trades hands at a multiple of just 2.4 times sales. PayPal stock is twice as expensive, at 4.8 times sales. Considering Square is growing revenue significantly faster than PayPal, that points to doubts from investors as to whether Square can reach similar margins as PayPal.

PayPal expects "stable to growing" operating margin going forward. On Square's third-quarter earnings call, the CFO said, "I would expect something more like mid-single-digit margin improvement in 2017 and use that as your cadence for the next several years." Whether it reaches PayPal's 13% operating margin is still a big question mark.

Both companies are executing well, and the market favors each based on their different focuses in operating metrics. For investors willing to take on a good amount of risk, Square could be a good investment based on its recent execution, outlook for the future, and current market valuation.

However, PayPal represents a well-established business that's still growing well in the face of growing competition, and it trades for a fair valuation despite nearing its all-time high. That makes it a better buy for most investors.