Meme stocks have taken over the market in 2021. Described loosely as stocks with high short interest and/or gamma squeeze potential that become popular on social platforms like Twitter and Reddit, meme stocks are a whole new classification of stocks for investors to follow.

While most meme stocks are downward-trending businesses trading at absurd valuations (like Gamestop and AMC Entertainment), a select few are actually strong companies that could be much larger five to 10 years from now.

Palantir (PLTR 0.56%) and Upstart Holdings (UPST -1.25%) are two meme stocks with legitimate long-term upside. Here's why.

A kid with a rocket on their back pointing to the sky.

Image source: Getty Images.

1. Palantir

Palantir is a software company that helps government agencies (mostly in the U.S.) and companies organize data to make informed decisions. This is a broad mandate but can be very useful for large organizations that have so many data points coming in daily. It only has 169 customers as of the end of the second quarter, but these customers are spending millions with Palantir each year. 

In the second quarter, total revenue grew 49% year over year to $376 million, with U.S. commercial revenue up 90% from 2020. Palantir closed 62 deals of $1 million or higher, including 21 deals north of $10 million. Clearly, organizations are finding value with the Palantir platform. Palantir is also profitable, with $233 million in adjusted operating income in the first half of this year. Investors have a lot of visibility into Palantir's future quarters, with total future deal value increasing 63% through the first half of 2021 to $3.4 billion.

Palantir stock is expensive, with a market cap of $52 billion versus only $1.3 billion in revenue over the past 12 months. However, if you believe that most large organizations across the globe will use Palantir's data insights, while also factoring in the high amount of future revenue already booked, Palantir's revenue and profits could be much higher a few years from now. This makes the stock a lot smarter to own than other meme stocks. 

2. Upstart Holdings

Upstart, like Palantir, is an artificial intelligence (AI)-focused company. But instead of serving large organizations, it is focused on the consumer lending market. The company has invented a better way to price loan default risk with consumers than traditional credit scores. It then partners with banks as a digital layer between them and the consumer, helping banks improve loss ratios and consumers get more fair access to loans. Upstart takes on minimal lending risks itself.

So far, Upstart's loan technology seems to be catching on extremely quickly. In the second quarter, total revenue grew 1,018% to $194 million, which shows how much banks are starting to use Upstart's lending algorithm. Upstart's bank partners originated 287,000 loans in the quarter, up 1,605% year over year. Even while growing this quickly, Upstart has been able to stay profitable, with $36.3 million in operating income last quarter. Upstart is also pushing heavily into auto loans with its acquisition of Prodigy. Auto loans are a $635 billion market, giving Upstart a long runway to grow if it can gain traction within the industry. 

Management is guiding for $750 million in revenue this fiscal year. With a market cap of $19.2 billion, that gives the stock a forward price-to-sales (P/S) ratio of 25.6. This is extremely expensive, but as with Palantir, if you believe Upstart can keep up this high rate of growth, this P/S could come down quickly within the next five years. And given the fact that Upstart is already profitable while growing its revenue so quickly, that indicates it can have strong profit margins once its business matures. That makes it a meme stock with real long-term business prospects.