The Nasdaq has risen 35% over the past 12 months as many investors have looked at tech stocks as safe havens during the COVID-19 crisis. But that rush also inflated the valuations of many attractive tech companies to unattractive levels.

As a result, it's tough to find any bargains in this frothy market which still faces unpredictable headwinds, including the presidential election, the gridlock regarding a stimulus deal, a second wave of COVID-19 infections, and the ongoing trade war with China. Those challenges could cause the market to crash. But instead of panicking, investors should see if the crash reduces the valuations of some pricey tech stocks to reasonable levels again.

Here are three stocks which I'd consider buying if the market crashes: Snowflake (NYSE:SNOW), MercadoLibre (NASDAQ:MELI), and Pinterest (NYSE:PINS). Let's find out a bit more about them.

A declining chart on a red background.

Image source: Getty Images.

1. Snowflake

Snowflake went public in mid-September at $120 per share, more than doubled on the first day, and currently trades at about $265 per share. The cloud services company is now valued at $73.6 billion, or 182 times its trailing 12-month sales, making it one of the market's priciest stocks.

Snowflake gathers data from a company's various computing platforms, then stores and analyzes it on a unified platform. Its service breaks down silos across an organization and makes it easier to make data-driven decisions.

There's robust demand for silo-busting services like Snowflake. That's why its revenue surged 174% in fiscal 2020, then rose another 133% year-over-year in the first half of 2021. It already serves nearly 30% of the Fortune 500, and its IPO attracted big investors like Warren Buffett's Berkshire Hathaway and

However, Snowflake remains unprofitable, and its net loss only narrowed slightly in the first half of 2021. It also faces competition from formidable rivals like Amazon's (NASDAQ:AMZN) Redshift. Those challenges make it a difficult stock to recommend at its current valuations. But if a market crash cuts Snowflake's stock in half, reducing its price-to-sales ratio back to its IPO level of about 80, I'd be willing to buy some shares.

2. MercadoLibre

Shares of MercadoLibre, the biggest e-commerce company in Latin America, soared 140% over the past 12 months. It operates in 18 countries, but its top three markets are Brazil, Argentina, and Mexico.

Tiny parcels on a laptop keyboard.

Image source: Getty Images.

MercadoLibre's revenue rose 60% last year, but it posted a net loss. In the first half of 2020, its revenue rose 50% year-over-year, as the pandemic sparked more online purchases, and it stayed profitable with 47% earnings growth.

Analysts expect its revenue to rise 54% for the full year with a stable profit as it optimizes its costly shipping subsidies and investments.

MercadoLibre's number of unique active users rose 38% year-over-year to 65.5 million in the first half of the year, while its gross merchandise volume (GMV) grew 30% to $8.5 billion. Its total payment volume (TPV), which is mainly processed through its Mercado Pago payments platform, rose 59% to $19.3 billion.

MercadoLibre looks like a sound long-term investment, but its stock trades at 250 times forward earnings and 13 times next year's sales. Those valuations make Amazon -- which trades at 57 times forward earnings and four times next year's sales -- look like a bargain. Therefore, a market crash could reduce MercadoLibre's valuations to more attractive levels.

3. Pinterest

Pinterest's stock has more than tripled since its IPO last April. The social media stock carved out a high-growth niche with its virtual pinboards, which attracted advertisers with shoppable pins and catalogs.

Pinterest's iPad app.

Image source: Pinterest.

Pinterest's revenue rose 51% last year, and it posted an adjusted EBITDA profit compared to a net loss in 2018. Its revenue rose 35% year-over-year in the first quarter of 2020, grew just 4% in the second quarter as the pandemic reduced ad purchases, but surged 58% in the third quarter as those advertisers accelerated their spending again.

Pinterest's monthly active users (MAUs) rose 37% year-over-year to 442 million during the quarter, led by its overseas growth, as its average revenue per user (ARPU) rose 15%. On the bottom line, its adjusted EBITDA soared from $4 million a year ago to $93 million.

It expects that momentum to continue with "around 60%" year-over-year revenue growth in the fourth quarter. Those growth rates are impressive, but Pinterest still isn't profitable on a GAAP basis, and its stock isn't cheap at 19 times next year's sales. By comparison, Facebook (NASDAQ:FB), which is firmly profitable, trades at just eight times next year's sales.

I don't expect Pinterest's stock to trade at the same price-to-sales ratio as Facebook, which is growing at a much slower rate, but a market swoon could offer investors a great opportunity to catch this high-flying stock.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.