Stock market crashes happen all the time, and often, they're quite forgettable, with investment values recovering quickly after the fact. But sometimes, a stock market crash can have long-lasting effects, and if you're retired, a major downturn could wreak havoc on your finances.

The good news? A few moves on your part could help you avoid getting hurt the next time the market tanks. Here are a few to focus on.

1. Have an emergency fund

It's not just working folks who need money in savings for a rainy day. As a retiree, you should also have a bank account that you can access in a pinch, and whose value won't hinge on how the stock market is performing. Ideally, that emergency fund should have enough money to cover six months' worth of living expenses or more. That way, if the market crashes, you'll have the option to leave your investments alone for a period of time while you wait for their value to come back up.

Older man at table looks at document while older woman on other side of table looks on

Image source: Getty Images.

2. Keep a healthy portion of your retirement savings out of stocks

It's important to keep your retirement savings invested in stocks, because that's what will deliver a high enough return to allow for a healthy withdrawal rate. Stick solely with bonds, and you'll have to withdraw from savings much more conservatively. At the same time, you shouldn't have too much of your long-term savings in stocks, because if the market takes a nasty turn for the worse, it could put you at risk of taking serious losses in your IRA or 401(k). As a general rule, you should have about 40% to 50% of your retirement savings in stocks during your 60s and 70s, with the rest of your assets allocated to bonds and cash.

3. Secure a home equity line of credit

Many seniors enter retirement with their homes already paid off. If that's the case for you, it could pay to apply for a home equity line of credit. That way, you're not borrowing money outright, but rather, you're getting access to money you can use when you need to. If the stock market crashes and you're afraid to touch your retirement savings for a year, you can rely on your home equity line of credit instead.

4. Adjust your savings withdrawal rate

There's a good chance the stock market will indeed crash at some point during your retirement. While you don't necessarily have to stop taking IRA or 401(k) withdrawals during that time (and you may not have that option anyway), one thing you should do in that scenario is withdraw from your retirement plan at a lower rate than usual. For example, if you normally withdraw at a rate of 4% a year, adjust that rate to 2.5% when the stock market is down, and cut back on expenses temporarily to get by on less.

5. Have a backup plan for generating income

When stocks are down, withdrawing from your long-term savings could mean locking in permanent losses. That's why it's smart to have another option for generating income that doesn't involve you touching your IRA or 401(k) -- namely, a job you can fall back on. If you're an accountant, stay current on the latest rules so you have the option to jump back in and take on clients as needed. If you're a retired teacher, stay registered with your school system so you can come on board as a long-term substitute, or build up a network of clients who might use your services as a tutor. While working during retirement may not be your first choice, it's something worth doing temporarily to account for poor stock market conditions.

The stock market crashes more often than any of us would like it to. But that doesn't have to throw off your retirement, and the better you prepare for a stock market downturn, the more likely you'll be to emerge from one unscathed.