You’re withdrawing money from a Roth IRA.You’re converting a traditional retirement account to a Roth IRA.You’ve inherited an IRA from someone who died.

The 5-year rule works differently in each of these three scenarios.

5-Year Rule for Roth IRA Withdrawals

The 5-year rule for Roth IRA withdrawals requires that you wait five years after opening your account to withdraw your investment earnings. Otherwise, taxes and a penalty will apply, though there are some exceptions that we’ll cover.  When you fund a Roth IRA, you don’t get an upfront tax deduction for your contribution. But you can withdraw the money tax-free and penalty-free if you wait until you’re at least 59 ½ and you’ve held the account for the five-year minimum. Suppose you opened your Roth IRA at age 57 and you’re now 61. You’ve contributed $5,000 a year for four years straight. Let’s say your account is now worth $30,000, consisting of your $20,000 in contributions, plus $10,000 of investment earnings. If you decided to withdraw $25,000 from your account, the first $20,000 would be completely tax- and penalty-free because that’s the amount of your contributions. The IRS always considers the first money you withdraw from a Roth IRA to be contributions. Earnings are only withdrawn once you’ve depleted your contributions. In this case, because you haven’t met the 5-year rule yet, you’d owe income taxes on the $5,000 of earnings. However, because you’re over 59 ½, you’d avoid a 10% early withdrawal penalty. If you’d waited one more year to withdraw the $5,000, you’d have avoided any tax bill whatsoever because at that point you’d have met the 5-year rule requirements. There are some exceptions to the 5-year rule. For example, you can avoid the 10% penalty if you become disabled or you withdraw up to $10,000 of earnings for what the IRS considers a first-time home purchase, even if you’ve had the account for less than five years. However, you’d still owe income taxes on the distribution in these scenarios. Once you’ve held the account for five years, you’d avoid both the 10% penalty and the taxes in both situations.

5-Year Rule for Roth IRA Conversions

The second 5-year rule applies to Roth IRA conversions. When you convert money from a traditional IRA or 401(k) to a Roth IRA, you pay income taxes at the time of the conversion. And, to take a tax-free distribution, you must leave the money in the account for at least five years or face a 10% penalty. A 10% additional penalty could also apply if you withdraw money before age 59 ½. Suppose you’re ineligible to contribute directly to a Roth IRA because your income is above the limits, which are $144,000 for single filers and $214,000 for married couples filing a joint return in 2022. ($153,000 for single filers and $228,000 for joint filers in 2023.) If this is the case, you could choose to use a backdoor Roth IRA—a workaround that lets you fund a traditional IRA and then convert the money to a Roth IRA. Under the 5-year rule, you’d need to: 

Wait at least five years to make tax-free withdrawals on your conversionsBe at least 59 ½ before you withdraw your money

Otherwise, unless you qualify for an exception, you’ll pay income taxes and a 10% early withdrawal penalty. You’d pay the penalty on the entire early distribution, rather than just the amount you contributed. The 5-year rule applies to each conversion. So if you converted $5,000 to a Roth IRA in 2020 and another $5,000 in 2021, you’d have to wait until at least 2025 to withdraw the first $5,000 and 2026 to withdraw the next $5,000.

5-Year Rule for Inherited IRAs

The final 5-year rule applies when you inherit a Roth IRA. You as a beneficiary have to take required minimum distributions (RMDs) . If the account wasn’t held for five years by the original owner, you’ll need to wait until the 5-year mark passes or the earnings will be subject to a tax. (But because the IRS considers the first withdrawals you make to have come from contributions, not earnings, you may not end up owing anything). If you inherited an IRA from someone who died on Jan. 1, 2020, or later, the SECURE Act rules will apply. This means that unless the deceased was your spouse, you’re required to withdraw all funds from the Roth within 10 years of the original account holder’s death. If you’re an inheriting spouse, you can create a stretch IRA and take distributions from it based on your life expectancy. But children and other beneficiaries must close the account within ten years. There’s another type of 5-year rule that applies to how you take distributions from an inherited Roth IRA. You can take distributions at any time within the five years after the original owner’s death. However, you must withdraw the entire balance by Dec. 31 of the fifth-year anniversary of their death. You could do this gradually, or in one lump sum. The penalty for not taking any required IRA distribution by the deadline is up to 50% of the amount that should have been withdrawn.