Contributing to a Roth IRA or 401(k) after 70 can benefit participants and their heirs.

Are you over age 70 and still working? You're not alone. Nearly 1 in 5 US residents between the ages of 70 and 75, and 1 in 10 aged 75 and older, continue to earn a paycheck, according to the Bureau of Labor Statistics.

That paycheck, along with company-sponsored health insurance, job satisfaction, or the camaraderie of coworkers, may be why you haven't opted for full retirement. But here's one benefit you might not have considered: tax-advantaged savings opportunities.

Contributing to a retirement account if you are working past age 70 might sound odd. But if you are still earning income, contributing to a Roth IRA, 401(k) or 403(b) plan, SEP-IRA, or a health savings account (HSA) may enable you to get tax benefits and potentially reduce a tax burden for your heirs. Note that you may not contribute to an HSA if you are enrolled in Medicare.

Here are 4 options for saving for retirement if you are 70 or older and have earned income. (Of course, you can utilize more than 1 option.)

Option 1: Roth IRA

Federal tax law allows you to contribute to a Roth IRA, if you meet the income limits, for as long as you have earned compensation, whether it is a regular paycheck or 1099 income for contract work. There's no age restriction. (A traditional IRA is off limits for new contributions after you reach age 70½.) You can contribute up to $6,500 (including a $1,000 catch-up contribution for those 50 or older) to a Roth IRA in 2018. Plus, you may be able to contribute another $6,500 for your non-working spouse, as long as your earned income is greater than $13,000. You can't contribute more than you earn.

A Roth IRA has IRS-mandated income limits. The modified adjusted gross income (MAGI) limit for 2018 is $199,000 if you're married filing jointly or a qualifying widow or widower, and your contribution is reduced if your income is between $189,000 and $199,000. For single taxpayers, the MAGI limit for 2018 is $133,000, with reduced eligibility between $120,000 and $135,000.

Here are some reasons why contributing to a Roth IRA may be a good idea:

No income taxes when you withdraw the money

You contribute money that has already been taxed (after-tax dollars) to a Roth IRA; contributions don't earn you an income tax deduction. But any growth or earnings from the investments in the account—and money you take out in retirement—is free from federal taxes (and usually state and local taxes too), with a few conditions.*

Tax diversification

Chances are you have a traditional 401(k) from another job and perhaps a traditional IRA. Withdrawals from these accounts are considered taxable income and subject to ordinary income tax rates. You've already paid the taxes on the money in a Roth IRA, so you can take out your money tax- and penalty-free. Mixing how you take withdrawals between Roth IRAs and your traditional IRAs, 401(k)s, or other qualified accounts may enable you to better manage your overall income tax liability; work with your advisor to determine the best approach. You could, for example, take withdrawals from a traditional IRA until your taxable income reaches the top of a tax bracket, and then take additional money you need from a Roth IRA.

No required minimum distributions

Many retirement accounts, such as a traditional IRAs and 401(k)s, are subject to required minimum distributions (RMDs) once you reach age 70½. A Roth IRA is not. That means the money can stay in the Roth IRA and continue to generate tax-free earnings.

Tax-free money for heirs

You can name beneficiaries to inherit the Roth IRA account when you die. The money in the Roth IRA will then pass to your heirs free from income taxes. An inherited Roth IRA is subject to RMDs, meaning the person who inherits the account must take withdrawals, but those withdrawals are generally not taxed. Keep in mind that the estate-planning value of a Roth IRA can be significant, but there are details and subtleties that should be discussed with an estate-planning professional to ensure that making a Roth IRA part of your estate plan is right for your situation.

Limited exposure to Medicare surtax

Current law imposes a 3.8% Medicare surtax on the lesser of net investment income or the excess of modified adjusted gross income (MAGI) above $200,000 for individuals, $250,000 for couples filing jointly, and $125,000 for spouses filing separately. RMDs from a traditional IRA or traditional 401(k) count toward the MAGI threshold for the surtax. Qualified withdrawals from a Roth IRA do not count toward the surtax's MAGI threshold, thus potentially reducing your exposure to the surtax.

Option 2: 401(k) or 403(b)

Workplace retirement savings accounts, such as 401(k)s and 403(b)s, also offer tax advantages for those who continue working past age 70. You can continue contributing to an employer-sponsored 401(k) plan for as long as you're working for that employer, no matter how old you are. The 2018 contribution limit for a 401(k) is $18,500, plus a $6,000 catch-up contribution for those age 50 and older.

Your employer might offer both a traditional and a Roth 401(k). A traditional 401(k) offers tax deferral. If lowering your current-year tax bill is your primary goal, then contributing to a traditional 401(k) can be a good strategy. A Roth 401(k) is similar to a Roth IRA, in that you contribute after-tax income and won't owe taxes when making a qualified withdrawal. When taxes are considered, a Roth 401(k) effectively has a higher contribution limit than a traditional 401(k). That's because an after-tax dollar contributed to a Roth 401(k) is worth more than a pre-tax dollar contributed to a traditional 401(k). On the other hand, a Roth 401(k), like a traditional 401(k), is subject to RMDs.

As long as you continue working for the company sponsoring the 401(k), you are not required to take an annual RMD. However, RMDs on both traditional and Roth 401(k)s kick in after you leave that employer, even if you work elsewhere. Also, you have to take RMDs if you own 5% or more of the company offering the plan.

Roth IRA or Roth 401(k), or both?

Here are some points to consider if you're weighing whether to contribute to a Roth 401(k) or a Roth IRA:

• You may be able to contribute more to a Roth 401(k) than a Roth IRA because the contribution limits are higher.

• Unlike a Roth IRA, a Roth 401(k) is not subject to an income limit on eligibility.

• Contributions within a Roth IRA are always available to be withdrawn, without taxes or penalties. Withdrawals of earnings from a Roth IRA are tax-free and penalty-free provided that the 5-year aging requirement has been satisfied and one of the following conditions is met: age 59½, death, disability, or qualified first-time home purchase. Contributions to a Roth 401(k) may not be as readily accessible.

• Unlike a Roth IRA, you are not required to take an annual RMD from a Roth 401(k) until you leave the employer or if you own 5% or more of the company offering the plan.

If you are able to contribute to both a traditional and a Roth 401(k), it may make sense to do that. Doing so can give you taxable and tax-free withdrawal options you can use for tax diversification in retirement.

Option 3: SEP IRA

A Simplified Employer Pension (SEP) IRA is a tax-advantaged retirement savings plan for self-employed individuals and small businesses. You can contribute to SEP IRA after you reach age 70. But once you reach age 70½, you have to take RMDs. So you could conceivably be contributing to your SEP IRA and reducing your current-year tax on one hand, while also taking an RMD and having to pay tax on the withdrawals on the other.

Depending on the amount of your RMD and the amount you intend to contribute, a SEP IRA may still be a good tax-planning tool if you're working past age 70. The 2018 contribution limit for a SEP IRA can be much higher than for a Roth IRA: $55,000 or 25% of eligible income, whichever is less.

Option 4: Health Savings Account (HSA)

If you enroll in Medicare (which usually occurs at age 65), you are not eligible to contribute to an HSA.

However, if you have not yet enrolled in Medicare and still have access to a high deductible health care plan from your employer, you can still contribute to an HSA. For the 2018 calendar year, you can contribute $6,900 to an HSA (plus a $1,000 catch-up contribution, if you are 55 or older) if you are enrolled in a family plan ($4,450 otherwise). It's permissible—and in fact is part of the HSA design—to make pre-tax HSA contributions and, in the same year, make tax-free withdrawals for qualified medical expenses. Since you are already over age 65, all withdrawals from your HSA are penalty-free, and if you use the funds to pay for qualified medical expenses, your withdrawals are federally tax-free too.

Taxation of HSA contributions and withdrawals can vary by state, so consult your financial or tax advisor on whether or not it makes sense for you to have an HSA.

Making a decision

There can be significant benefits to continuing to contribute to a tax-advantaged retirement account if you are working into your 70s and beyond. In addition to the points covered here, other considerations include the impact that continuing to work may have on your Social Security benefits, and the goals in your retirement plan.

As always, the advice of a qualified tax professional may help you make the choices that are best for you.

* A distribution from a Roth IRA is tax free and penalty free, provided that the five-year aging requirement has been satisfied and at least one of the following conditions is met: you reach age 59½, become disabled, make a qualified first-time home purchase ($10,000 lifetime limit), or die. Required minimum distributions do not apply to the original account owner, although heirs will be subject to them.

Fidelity does not provide legal or tax advice. The information herein is general and educational in nature and should not be considered legal or tax advice. Tax laws and regulations are complex and subject to change, which can materially impact investment results. Fidelity cannot guarantee that the information herein is accurate, complete, or timely. Fidelity makes no warranties with regard to such information or results obtained by its use, and disclaims any liability arising out of your use of, or any tax position taken in reliance on, such information. Consult an attorney or tax professional regarding your specific situation.