Building long-term wealth may seem like a daunting task, but it's simpler than you might think. Whether you're saving for retirement or simply trying to increase your net worth, the right strategy can help you generate hundreds of thousands of dollars over time.

Generation X is generally defined as including those born between 1965 and 1980, or ages 44 to 59. This can be the perfect time of life to supercharge your net worth, especially heading into retirement age.

The median net worth of those between ages 45 and 54 is $247,000, according to a report from The Motley Fool using data from the Federal Reserve, and those between ages 55 and 64 have a median net worth of $364,000.

While the amount of wealth you're able to build will depend on your unique situation, there are a few steps you can take to maximize your net worth.

Person sitting at a desk using a laptop.

Image source: Getty Images.

1. Pay down expensive debt

Most people have some form of debt, whether it's a mortgage, car loan, or credit card debt. But high-interest debt -- such as credit card debt and many short-term loans -- can be incredibly costly over time.

The average credit card interest rate is a whopping 24.59%, according to data from LendingTree. If that debt is snowballing over time, you could end up paying thousands of dollars in interest alone.

Not only does high-interest debt make it harder to save, but it also reduces your net worth. Your net worth is calculated by subtracting your liabilities (such as debt) from your total assets. The less debt you have, then, the higher your net worth will be.

2. Build an emergency fund

An emergency fund is key to generating wealth, because it can help you avoid pulling money out of your retirement fund or investment accounts if you face an unexpected expense.

If you're investing in a 401(k) or traditional IRA, for example, you generally can't touch that money until age 59 1/2. By withdrawing your cash before that age, you could potentially face income taxes and a 10% penalty on the amount you withdraw.

Even if you're investing in an account that doesn't penalize withdrawals, you still risk withdrawing your money at a bad time. If stock prices fall and you're forced to make a withdrawal, you could end up selling your investments for less than you paid for them -- locking in those losses.

A good rule of thumb is to sock away enough cash to cover at least six to 12 months' worth of general living expenses. If you do face an unexpected expense, then, you can leave your investments alone and save money on taxes, penalties, or other losses.

3. Don't just save -- invest

Investing in the stock market is one of the simplest and most effective ways to build wealth. There are plenty of ways to invest -- from contributing to a 401(k) to investing in individual stocks -- and there's a strategy that will fit every lifestyle.

By investing consistently, you could earn hundreds of thousands of dollars over time. For example, say you're contributing $400 per month to your 401(k) and earning a modest 8% average annual return on your investments -- which is just below the stock market's historic average.

In another scenario, say you're still saving $400 per month, but instead of putting it in a 401(k), you're stashing it in a high-yield savings account earning 2% annual interest. Here's approximately how your savings would add up in both situations:

Number of Years Total Portfolio Value: 2% Average Annual Return Total Portfolio Value: 8% Average Annual Return
15 $83,000 $130,000
20 $117,000 $220,000
25 $154,000 $351,000
30 $195,000 $544,000

Data source: Author's calculations via investor.gov.

Investing can be daunting at times, especially during periods of volatility. But over the long term, the stock market is safer than it may seem. Choosing the right investments is key, and with a healthy portfolio, you're much more likely to earn positive returns over time -- and generate far more wealth than if you were to simply save in a savings account.

Building a net worth of hundreds of thousands of dollars takes time and consistency, but it is possible. By paying down debt, building a healthy emergency fund, and investing as much as you can afford, you'll be on your way to generating wealth that lasts a lifetime.