What Order Should You Fund Retirement Accounts?
What Order Should You Fund Retirement Accounts?
You have identified which accounts are available to you—401(k), IRA, HSA, solo 401(k)—but the order in which you fund them matters enormously. Funding in the wrong sequence wastes tax-deduction potential, misses employer matches, or leaves tax-advantaged space unused. A general rule exists, but your specific situation (income, employer match structure, self-employment income, age) determines the optimal path. This article walks you through a decision framework to sequence your contributions and maximize your tax-advantaged savings year after year.
Quick definition: Account funding priority is the sequence in which you direct your savings toward different retirement accounts to maximize tax benefits, employer matches, and contribution efficiency.
Key takeaways
- Universal priority: fund 401(k) to the employer match first (non-negotiable).
- Second priority: max HSA (if eligible and available) before IRAs, due to triple-tax advantage.
- Third: max a traditional or Roth IRA (depending on income and tax situation).
- Fourth: return to the 401(k) and fund beyond the match (if you have remaining savings).
- Fifth: execute mega backdoor Roth (if your plan allows and your income exceeds Roth limits).
The universal priority: capture the match first
No financial decision is more clear-cut than capturing an employer match. An employer match is free money—an immediate return on your contribution. If your employer matches 50% of the first 6% of salary, contributing 6% yields a 50% instant return, equivalent to no investment earning 50% annually. This is higher than virtually any risky asset and certainly beats keeping money in a savings account.
How much do you need to contribute to capture the full match? Check your plan documents or benefits materials. The most common structure is "100% match on the first 3%" (you contribute 3%, they contribute 3%) or "50% match on the first 6%" (you contribute 6%, they contribute 3%). A smaller number, like "25% match on the first 4%," requires contributing 4% to get the full benefit.
Scenario: You earn $60,000 and your employer matches 100% of the first 3%. You need to contribute just $1,800 (3% of $60,000) to capture the full $1,800 match. Skipping this to fund a lower-fee IRA instead is a mistake; no IRA will outperform a guaranteed 100% match.
Once you have determined the match target, fund your 401(k) up to that level before doing anything else with retirement savings. This is non-negotiable.
Second priority: max the HSA if eligible
If you are enrolled in a high-deductible health plan (HDHP), you are eligible for a Health Savings Account (HSA). HSAs have the most favorable tax treatment of any retirement account: contributions are deductible, growth is tax-free, and withdrawals for qualified medical expenses are tax-free. For comparison, traditional IRAs are only deductible + tax-deferred growth, and Roth IRAs are only tax-free growth. HSAs are all three.
As of 2025, HSA contribution limits are $4,150 for self-only coverage and $8,300 for family coverage. These limits are modest compared to a 401(k) ($23,500), but they are also often overlooked by workers who focus only on their 401(k). Many financial advisors recommend maxing an HSA before maxing an IRA, due to the superior tax treatment.
An additional advantage: you can accumulate HSA funds without spending them on medical expenses immediately. If you pay out-of-pocket for medical costs and retain the receipts, you can reimburse yourself from the HSA decades later, creating a massive tax-free withdrawal. After age 65, you can withdraw HSA funds for any reason without penalty (though non-medical withdrawals are taxed as ordinary income, like a traditional IRA). This makes the HSA a stealth retirement account: contribute young, invest tax-free, and withdraw tax-free (or tax-deferred) in retirement.
Funding sequence if you have HSA access: capture the 401(k) match, then max the HSA, then move to IRA and beyond.
Third priority: max a traditional or Roth IRA
After capturing the match and maxing the HSA, the next priority is maximizing an IRA. The choice between traditional and Roth depends on your income and tax situation (discussed in previous articles). An IRA contribution of $7,000 (or $8,000 with catch-up at age 50) is a smaller step than a 401(k), but it is still substantial—$91,000 cumulatively over a 13-year career from age 30 to 42.
If your income is below the Roth IRA phase-out limit (around $150,000 for singles in 2025), you can contribute directly to a Roth IRA. If your income exceeds this, you can either contribute to a traditional IRA (if you qualify for the deduction) or execute a backdoor Roth (contribute to a non-deductible traditional IRA and convert to Roth immediately).
Why prioritize IRA over returning to the 401(k) at this stage? Because IRAs typically offer more investment flexibility, lower fees, and tax diversification. A 401(k) is often limited to a fund menu with higher expense ratios. An IRA lets you build a customized portfolio of low-cost index funds or individual stocks. For most workers, maxing an IRA before returning to the 401(k) provides better long-term returns.
Fourth priority: return to the 401(k) beyond the match
Once you have captured the match, maxed the HSA, and maxed the IRA, any remaining savings should go back into the 401(k) (if you have not yet reached the $23,500 limit). This is a simple principle: fill the highest-limit account first (the 401(k)), then max the lower-limit accounts (HSA, IRA), then return to the 401(k) to use any remaining limit.
Why? Contribution limits are finite. If you defer $23,500 to a 401(k), you have hit that limit and cannot defer more to that account. But you can also fund an IRA ($7,000), an HSA ($4,150–$8,300), and other accounts in the same year. Maxing lower-limit accounts does not reduce the 401(k) limit; it is additive. So you can maximize your total tax-advantaged deferral by sequencing strategically.
Example: You earn $120,000 and can save $40,000 this year. Here is the optimal sequence:
- Contribute $3,600 to the 401(k) to capture a 100% match on the first 6% of salary.
- Contribute $4,150 to the HSA (your self-only coverage limit).
- Contribute $7,000 to a Roth IRA.
- Contribute the remaining $25,250 to your 401(k), bringing your 401(k) total to $28,850 (above the $23,500 limit).
Wait—that exceeds the $23,500 limit. Let me recalculate:
- Contribute $3,600 to the 401(k) to capture the match.
- Contribute $4,150 to the HSA.
- Contribute $7,000 to the Roth IRA.
- You have $25,250 left. Your 401(k) room is $23,500 total, so you can contribute an additional $19,900 to hit the limit. The remaining $5,350 goes to taxable investing.
This maximizes tax-advantaged space: $3,600 + $19,900 = $23,500 in the 401(k), $4,150 in HSA, $7,000 in IRA, for a total of $34,650 tax-advantaged. The remaining $5,350 is taxable.
Fifth priority: mega backdoor Roth (high earners only)
If your 401(k) plan allows after-tax contributions and in-service Roth conversions (the mega backdoor Roth setup), and if your income exceeds the Roth IRA phase-out limit, this becomes your fifth priority after the preceding steps.
The mega backdoor Roth allows you to contribute after-tax dollars to the 401(k), up to the plan's total limit (approximately $70,000 in 2025), and immediately convert that after-tax amount to Roth. Because you are converting already-taxed money, there is no additional tax. The conversion moves after-tax dollars to Roth, where they grow tax-free forever.
This is only relevant if:
- Your plan allows after-tax contributions and in-service conversions (not all do).
- Your income exceeds direct Roth IRA limits (you do not qualify for direct Roth contributions).
- You have already captured the match and funded other accounts.
For someone earning $250,000, the mega backdoor Roth might allow an additional $40,000–$50,000 in annual after-tax contributions. This is the fifth and final priority in a comprehensive sequence.
Different paths for different life circumstances
The five-tier priority applies to most W-2 employees with employer 401(k) access. But your situation might diverge:
No employer 401(k) available. If you are self-employed or your employer does not offer a plan, your sequence is simpler: max HSA (if eligible), max IRA (or backdoor Roth if income is too high), then consider a solo 401(k) or SEP IRA for additional space.
Self-employed with significant income. A freelancer earning $150,000 might skip a traditional IRA and instead max a solo 401(k), which allows much higher contributions. The sequence might be: capture any self-employed health insurance deduction, max the HSA, then max the solo 401(k).
Early career, low income, high tax uncertainty. A 25-year-old earning $40,000 might prioritize Roth contributions (locking in a low tax rate) over pre-tax deferrals. The sequence might be: capture match (if any), fund HSA, then max a Roth IRA (or Roth 401(k) if available), before return to traditional 401(k).
High earner with mega backdoor access. A software engineer at a tech company earning $300,000 might sequence as: capture match, max HSA, backdoor Roth IRA, max 401(k) to the standard limit, then mega backdoor Roth with remaining plan space.
Couple with both spouses working. If both spouses have access to employer 401(k)s and HSAs, they can multiply the limits: two 401(k)s ($47,000 combined), two HSAs ($16,600 for family coverage combined), two IRAs ($14,000), potentially totaling $77,600+ in annual tax-advantaged deferrals.
Adjusting for age and catch-up contributions
Starting at age 50, you become eligible for catch-up contributions, increasing limits by $7,500 on 401(k)s and $1,000 on IRAs. Adjust your priority sequence at age 50 to account for this extra room.
For someone turning 50 who previously maxed only the IRA and HSA, the new priority becomes: capture match, max HSA, max IRA (now $8,000), and use the additional $7,500 401(k) catch-up space. This potentially adds $8,500 in annual deferral at an age when you are more likely to have additional income and less financial obligations (children may be independent, mortgage may be paid off).
Tax law changes and flexibility
Tax rules can change. The current limits and contribution rules assume 2025 tax law. The SECURE Act 2.0 introduced new rules around RMDs, backdoor Roths, and other features that may shift optimal sequencing. As rules evolve, revisit your strategy annually. Consult a tax professional if major changes occur.
Real-world examples
Example 1: Entry-level employee, low income. Alex, age 25, earns $45,000 and works for a company with a 401(k) offering a 100% match on the first 3%. He can save $8,000 annually. His sequence: contribute $1,350 to the 401(k) to capture the $1,350 match, max an HSA at $4,150, then max a Roth IRA at $7,000. Wait—that is $12,500 and he only has $8,000 to save. So: contribute $1,350 to 401(k) for match, contribute $4,150 to HSA, leaving $2,500 for a Roth IRA (partial). He falls short of maxing the IRA but maximizes the match and HSA, which are highest-priority. Next year as his income grows, he can prioritize the IRA.
Example 2: Mid-career professional, solid income. Jennifer, age 40, earns $110,000 and can save $25,000 annually. She has access to a 401(k) with a 50% match on the first 6%, an HDHP with HSA, and she qualifies for direct Roth IRA contributions. Her sequence: contribute $3,300 to the 401(k) (6% of $110,000) to capture the full $1,650 match. Contribute $4,150 to HSA. Contribute $7,000 to Roth IRA. Contribute the remaining $10,550 to her 401(k), reaching $13,850 total in the 401(k). This maxes the match, HSA, and Roth IRA within her $25,000 savings goal.
Example 3: High earner with mega backdoor opportunity. Mark, age 45, earns $220,000, is ineligible for direct Roth contributions (income too high), and works for a company whose 401(k) allows after-tax contributions and in-service Roth conversions. He can save $60,000 annually. His sequence: contribute $14,000 to the 401(k) to capture the employer match and profit-sharing (varies by plan). Contribute $8,300 to HSA (family coverage). Contribute $23,500 to the 401(k) via backdoor Roth (he uses non-deductible traditional IRA contributions converted to Roth). Contribute $14,200 to the 401(k) as after-tax contributions, immediately converting to Roth. His 401(k) total is $14,000 (match/profit-sharing) + $23,500 (employee deferrals) + $14,200 (after-tax) = $51,700, near the $70,000 plan limit. This sequence shelters $60,000 entirely in tax-advantaged accounts.
Example 4: Self-employed freelancer. Sarah, age 50, is a consultant earning $200,000 net self-employment income. She has no W-2 employment income and no access to an employer 401(k). Her sequence: maximize self-employed health insurance deduction ($4,000). Contribute $4,150 to HSA (if eligible). Contribute $8,000 to a Roth IRA (she qualifies; catch-up applies as she is over 50). Open a solo 401(k) and contribute $23,500 in employee deferrals (catch-up, age 50) plus approximately $40,000 in employer contributions (20% of net self-employment income). This totals roughly $75,500 in tax-advantaged deferral, leveraging both the IRA and solo 401(k).
Common mistakes
Mistake 1: Funding the IRA before capturing the full employer match. The match is free money and should never be skipped. An IRA cannot match the guaranteed 50–100% return of a match. Always prioritize the match.
Mistake 2: Maxing the 401(k) without funding the HSA. An HSA is more tax-efficient than a 401(k) and should be maxed before fully funding a 401(k). Many workers miss this because they focus on the 401(k) as their primary retirement vehicle.
Mistake 3: Assuming you cannot execute a backdoor Roth if your income is too high. Even if your income exceeds Roth limits, you can contribute to a non-deductible traditional IRA and convert to Roth immediately (a backdoor Roth). This is a legal and effective tool overlooked by many high earners.
Mistake 4: Failing to revisit your sequence annually. Contribution limits change, employer plans change, your income changes, and tax law changes. What was optimal last year might not be this year. Revisit your funding order at the start of each year.
Mistake 5: Forgetting to capture the match in a new job. When you start a new job, the match rules are different. You need to contribute to the new employer's 401(k) to capture their match; your old employer's match does not continue. Many job-changers accidentally skip the match for a quarter or year because they forgot this detail.
FAQ
If I have $20,000 to save and get a full match at $3,000, what is the optimal sequence?
- Contribute enough to the 401(k) to capture the full $3,000 match (let us say $5,000 total 401(k) contribution).
- Contribute $4,150 to HSA.
- Contribute $7,000 to IRA.
- Contribute the remaining $3,850 to the 401(k).
- You have $20,000 total, hitting all priorities except fully maxing the 401(k).
Should I change my sequence if I expect a major tax law change?
If you anticipate a significant change (e.g., sunset of tax cuts, new rate structure), consider consulting a tax professional to adjust your mix of pre-tax versus Roth. Generally, it is hard to predict, so a balanced approach (some pre-tax, some Roth) hedges the uncertainty.
What if my employer 401(k) has terrible funds and high fees?
Capture the match (free money outweighs high fees), then prioritize the HSA and IRA (which likely have better options and lower fees). Once you have maximized the match, HSA, and IRA, return to the 401(k) only if you have no other options and additional savings you want to defer.
Can I split my contributions to achieve tax deductions and Roth growth in the same year?
Yes. You can contribute some money pre-tax (traditional IRA or 401(k) pre-tax deferrals) and some after-tax (Roth IRA or Roth 401(k)). Many advisors recommend this for tax diversification, allowing flexibility in retirement to manage your tax bracket.
Should my spouse follow the same priority sequence?
Generally yes, assuming both have similar income and access to accounts. However, if your spouse earns significantly less or has no W-2 income, the strategy might differ (spousal IRA contributions, for example). Coordinate with your spouse and consider filing taxes jointly to maximize benefits.
Related concepts
- Contribution Limits Overview
- Choosing Between Account Types
- Self-Directed IRAs
- Account Types Decision Framework
- Mega Backdoor Roth and Power Moves
Summary
The optimal account funding sequence starts with capturing the employer 401(k) match (non-negotiable), then maxes the HSA (most tax-efficient), then maxes an IRA or backdoor Roth. Any remaining savings return to the 401(k) to use remaining contribution space. High earners with mega backdoor Roth plans add a fifth tier: after-tax 401(k) contributions converted to Roth. Your specific sequence depends on your income, employment situation, age, and access to accounts. Revisit your sequence annually as contribution limits, tax law, and your financial situation change.