The stock market is going to tank at some point. Whether that happens next week, next month, or next year is anyone's guess.

It's actually pretty common for the stock market to undergo corrections, where it loses at least 10% of its value but less than 20%. Full-blown stock market crashes are, thankfully, less common.

But to some degree, they're also unavoidable. So it's best to be prepared to face one, whether it happens in the near term or not. Here are a few things you can do to gear up for an extreme drop in stock values.

A person with a serious expression at a laptop.

Image source: Getty Images.

1. Load up on emergency savings

You never know when life might throw you a curveball, whether it's a lost job or a roof that decides to cave in and leave you with an emergency repair on your hands. That's why it's so important to have a well-funded savings account. In fact, as a general rule, you should aim to have enough money in savings to cover three to six months of essential bills.

Loading up your emergency fund is an essential part of preparing for a stock market crash, because the last thing you'll want to have to do during a downturn is liquidate investments at a loss when a sudden need for money arises. But if you set yourself up to cover unplanned bills, you'll buy yourself the option to leave your portfolio untouched during a stock market crash, thereby riding out that turbulence and avoiding losses.

2. Diversify your holdings

A diverse portfolio could be your ticket to riding out a stock market crash. As such, take a look at your holdings and make sure you own stocks across a range of different sectors.

It's also a good idea to own investments outside of stocks. Bonds are a good bet if you're older, but if you're fairly young, you'll want to keep those to a minimum due to their less generous returns.

You can branch out in your portfolio by putting some money into REITs, or real estate investment trusts. REIT values don't always correlate directly to movement in the stock market, so buying REITs is a good way to diversify within the context of real estate without taking on the risk or hassle of owning physical properties.

You may even decide to diversify your holdings in the form of buying crypto. Though crypto is extremely volatile even in the best of times, it's another asset class you can own so you're not overloaded on stocks alone.

3. Have the right attitude

Some stock market downturns are more prolonged than others. In March of 2020, when stocks tanked in the wake of the COVID-19 outbreak, the crash at hand was fairly short-lived. But that doesn't mean our next market downturn will be so brief.

That's why a big part of preparing for a stock market crash is adjusting your attitude and telling yourself that if your portfolio value stays down for a while, you will get through it. If you grow panicked over a prolonged downturn, you may be driven to dump investments to minimize your losses -- all the while locking those losses in rather than avoiding them completely.

The idea of a stock market crash can be scary, but it's important to acknowledge the fact that you'll probably have to face one sooner or later. If you make these moves to prepare, you'll put yourself in a great position to ride out that storm and emerge unscathed.