Experts often recommend saving up $1 million before you retire. While many people are able to live on much less than that, for others $1 million may not be enough, thanks in part to longer life expectancy and disappearing pensions. At the same time, many financial planners also suggest saving anywhere between 10% and 15% of your gross salary.
But to be able to comfortably save while also building a multi-million-dollar retirement fund, you'd need to earn a substantial salary. In most situations, that means bringing in far more than $61,372, the median household income in the U.S.
Below, CNBC calculated the amount you need to earn annually in order to save $2 million by 65 by putting 10% of your earnings into investments.
For context, the average American's 401(k) plan grew at a compound annual average rate of 14.2% between 2010 and 2016, according to a study of more than 6 million accounts by the Employee Benefit Research Institute, a nonprofit based in Washington, D.C. Of course, there's no guarantee of similar growth in the future.
Keep in mind that these numbers don't take into account the many ups and downs you may experience over your lifetime, including periods of unemployment or sudden financial windfalls or losses.
It's also important to consider how pay increases will affect your savings over time. If you consistently put away 10% of your income, the actual amount you contribute each month will grow as your salary rises, which can help you build up your retirement fund more quickly.
Even if you don't earn much now, save what you can and work your way up to 10 or 15%. As your salary rises, increase your retirement contributions as well. If you're aiming for that $2 million, you might need to consider contributing even more than 15% of your income, depending on your salary.
A good place to start investing for retirement is your employer-sponsored 401(k) plan. You should aim to contribute at least enough to earn any company match, which is essentially free money. If your company doesn't offer a 401(k) or comparable plan, or you max out your 401(k) for the year, you can still save for the future. Look into other retirement savings vehicles that offer tax benefits, such as a Roth IRA, traditional IRA and/or a health savings account. Beyond tax-advantaged account, you should also consider a brokerage account.
Remember: The most important factor in building a well-funded retirement account is to start saving and investing as much as you can as early as you can. You want to take advantage of compound interest, which is when any interest earned then accrues interest on itself.
No matter the amount you're contributing, the earlier you're able to start socking money away, the bigger the boost the stock market will give you.
Like this story? Subscribe to CNBC Make It on YouTube!