Robinhood has inspired a generation of young investors to jump into the stock market and start saving for the future. But that's just half the battle. The other half is learning to identify high-quality investment opportunities.

For context, the average Robinhood user is 31 years old, meaning they have roughly three decades before retirement. Given that time horizon, a long-term buy and hold strategy can create life-changing wealth. With that in mind, both Palantir (PLTR -7.67%) and Square (SQ -7.74%) look like smart investments for Robinhood traders.

Data scientist reviewing information at her desk.

Image source: Getty Images

1. Palantir

Modern enterprises generate a tremendous amount of data. Unfortunately, they also rely on an ever-expanding number of applications and infrastructures, and the data created by those technologies is often stored across siloed systems.

Palantir was designed to solve this problem. Its software platforms -- Gotham and Foundry -- allow clients to integrate, analyze, and understand data. To put it more simply, Palantir helps its clients operate more efficiently by making data-driven decisions.

Gotham was specifically designed for government clients. American intelligence agencies have used this technology in counterterrorism efforts in places like Afghanistan and Iraq. Meanwhile, Foundry brings the same functionality to the commercial sector, helping clients solve complex problems across industries, from healthcare and energy to manufacturing and retail.

In both cases, Palantir provides granular access controls, allowing clients to monitor and manage who can access data and for what purpose. The secure nature of its platform is further evidenced by the company's history with the CIA and FBI. These intelligence organizations use Gotham to extract insights from troves of top secret data -- and if they're satisfied with Palantir's security standards, I doubt many other companies will have objections.

Financially, Palantir's numbers look pretty good. Revenue hit $1.1 billion in 2020, up 47% from the prior year, and sales growth actually accelerated to 49% in Q1 2021. On the bottom line, Palantir generated $116 million in free cash flow during the first quarter, and the company is now free-cash-flow positive on a trailing-12-month basis. In other words, the company can fund its operations without issuing new debt or equity. 

As a caveat, Palantir has just 149 clients, and the average revenue per client rose 29% to $8.1 million in Q1 2021. Investors should keep an eye on this in Q2 earnings, which will be reported on Aug. 12. As things stand, the company would take a big hit if it lost just a few customers.

Despite this risk, I think the future looks bright for Palantir. Management puts its market opportunity at $119 billion, and the company believes it can grow revenue by at least 30% per year through 2025. That's why you should consider buying a few shares of this growth stock.

A couple shopping online.

Image source: Getty Images

2. Square

Square's mission is to help everyone participate and thrive in the economy. To that end, its Seller ecosystem includes hardware, software, and services that help merchants manage their business across digital storefronts and physical locations. 

On the flip side, Square's Cash App ecosystem is designed for consumers. This product unifies banking and brokerage services, allowing users to send, spend, and invest money from a single platform. Notably, Square recently redesigned its user interface, simplifying the deposit process. That may sound trivial, but cash inflows are the primary driver of Cash App gross profit.

Earlier this week, Square reported second-quarter results, and once again the numbers were impressive. Gross profit surged 91% to $1.1 billion, driven by strong growth in both the Seller and Cash App ecosystems. The company also reported a profit of $0.40 per diluted share, up from -$0.03 per diluted share in the prior year.

Looking ahead, I think Square is well positioned to maintain its momentum. The company recently announced plans to acquire buy now, pay later (BNPL) firm Afterpay for $29 billion in stock. Despite that big price tag, this move could supercharge growth across Square's business.

How will that happen? Afterpay's platform offers a range of benefits for sellers, including improved conversion, larger basket size, and increased purchase frequency. At the same time, the Cash App should see a boost in engagement, as users will be able to use the platform to discover merchants and BNPL offers. 

That's why this stock looks like a smart long-term investment.