Search
CoursesStock researchPaper tradingNews
HomeAbout
A two-storey yellow house with a front porch on a tree-lined street

Photo: Corey Coyle / Wikimedia Commons, CC BY 3.0, cropped

Max Your 401(k) or Pay Down the Mortgage? The Math at 3%, 5% and 7% Mortgage Rates (2027)

Quick answer
  • Always get the full employer match first. A 50% match beats paying down any normal mortgage.
  • 3% mortgage: invest in the 401(k). Paying down cheap debt gives up a lot of expected growth.
  • 5% mortgage: 401(k) still leads, but by less. Splitting extra money is reasonable.
  • 7% mortgage: after the match, it's roughly a tie on expected returns, and paying the mortgage is guaranteed. Many people should prepay.

The question

You have extra money each month. Do you put it into your 401(k) or send it to your mortgage? The honest answer is that it depends mostly on your mortgage rate. Here's the math at 3%, 5% and 7%.

How we compared them

The results

Option After-tax value after 10 years Risk
401(k), with a 50% match ($3,000 a year) $140,098 Market
401(k), no match $107,768 Market
Pay down a 7% mortgage $107,768 Guaranteed
Pay down a 5% mortgage $98,108 Guaranteed
Pay down a 3% mortgage $89,418 Guaranteed

Three things stand out:

  1. The match wins by a mile. Free money adds more than $32,000 here. Never skip it to pay down a mortgage.
  2. At 3% and 5%, the 401(k) leads by about $18,000 and $10,000 on expected returns.
  3. At 7%, it's a dead heat. That's not a coincidence: when the mortgage rate equals the expected return and the tax rate is the same going in and coming out, the two are mathematically equal. One is guaranteed; the other isn't.

If you retire in a lower bracket, the 401(k) gets better. Taxed at 12% instead of 22% on the way out, the no-match 401(k) is worth about $121,584, ahead of even the 7% mortgage.

At a 3% mortgage: invest

A 3% fixed rate is cheap money, often below inflation. Paying it down early gives up a lot of expected growth. Put extra money into the 401(k), a Roth IRA or a taxable account, and let the mortgage run on schedule.

At a 5% mortgage: 401(k) first, but consider splitting

The 401(k) still leads on expected returns, but the gap is narrower and the mortgage side carries no risk. A split, such as getting the match plus a Roth IRA, then sending the rest to the mortgage, balances growth and security.

At a 7% mortgage: prepaying is a strong choice

After the match, a guaranteed 7% is hard to beat on a risk-adjusted basis. It's similar to what stocks have earned over long periods, without the bad years. For many people, especially those in their 50s or more cautious investors, prepaying a 7% mortgage after the match is the better plan. If rates fall, refinancing may change the math again.

The order most people should follow

  1. Emergency fund of 3 to 6 months of expenses. Home equity is hard to get at when you need cash.
  2. 401(k) up to the full employer match.
  3. Pay off high-interest debt such as credit cards.
  4. Mortgage at 6% or more? Lean toward extra principal payments. 4% or less? Lean toward investing. In between? Split.
  5. Max out tax-advantaged accounts: the 401(k) limit is $25,500 in 2027, and the IRA limit is $7,500.

Things the spreadsheet misses

The bottom line

Get the match first, always. Then let your mortgage rate decide: at 3%, invest; at 5%, lean toward investing or split; at 7%, prepaying the mortgage is about as good on expected returns and much safer. To make the most of the 401(k) side, see 401(k) Limit 2027: How to Max Out and Roth 401(k) vs Traditional 401(k) at $50K, $100K and $150K.

Figures: 2027 IRS limits and standard deduction, 22% federal bracket, USD. Investment returns are illustrative, not guaranteed. Mortgage value is principal paid plus interest avoided, compounded at the mortgage rate.

Elizabeta’s take

This is one of those questions where the spreadsheet and the feeling don't always agree, and I think both deserve a vote. With a 3% mortgage, I'd invest without thinking twice. With a 7% mortgage, a guaranteed 7% is a great return, and the peace of mind of owning your home sooner is real. Just never skip the match to do it, and keep an emergency fund, because you can't pay the grocery bill with home equity.

— , founder of RiskStock

Frequently asked questions

Should I max out my 401(k) or pay off my mortgage early?

Get the full employer match first in every case. After that, it depends on your mortgage rate. With a rate around 3%, investing in your 401(k) usually comes out well ahead. Around 5%, the 401(k) still leads on expected returns. Around 7%, the two are roughly even, and paying down the mortgage has the advantage of a guaranteed return.

Is paying off a mortgage a guaranteed return?

Yes. Every extra dollar of principal saves you interest at your mortgage rate for the rest of the loan, with no market risk. A 401(k) invested in stocks has a higher expected return over long periods but can fall in value along the way.

Does the mortgage interest deduction change the answer?

Only if you itemize. With a 2027 standard deduction of $33,200 for married couples and $16,600 for single filers, most homeowners don't itemize, so their mortgage interest saves no federal tax. If you do itemize, your effective mortgage rate is a little lower, which tilts further toward the 401(k).

What if I'm close to retirement?

Many people like to enter retirement without a mortgage, because it lowers the income they need to withdraw each year, which can also keep their tax bracket low. In your last working years, paying down a higher-rate mortgage can make more sense, but keep enough liquid savings.

Is there a penalty for paying off my mortgage early?

Most US mortgages today have no prepayment penalty, and qualified mortgages limit them. Check your loan documents. When you send extra money, make sure the lender applies it to principal.

What about a Roth IRA instead of either?

A Roth IRA is a strong option after the 401(k) match. In 2027 you can contribute up to $7,500 ($8,600 at 50+) if your income qualifies. Roth contributions can be withdrawn at any time, which gives you more flexibility than either home equity or a 401(k).

Primary sources

Data & disclaimer: This article is for educational purposes only and is not financial or investment advice. Figures reflect data available as of Dec 5, 2026, and conditions change — always confirm current pricing, rates and rules with the provider before you act. Written by Elizabeta Dimoska. See our editorial standards and disclosure.

ED
About the author

Elizabeta Dimoska

Founder and writer of RiskStock. Self-directed investor covering ETFs, long-term investing, tax-advantaged accounts (TFSA, RRSP, Roth IRA, 401(k)), retirement, macro, and markets — in plain English, with every claim tied to a primary source. Not a licensed financial advisor; RiskStock is educational. See our editorial standards.

More from Elizabeta Dimoska →

RiskStock is independent and free to read. No paywall. Some articles contain affiliate links, which we always label. If this piece helped you, you can support our work.

☕ Buy me a coffee

Comments

Want More Like This?

Get our weekly newsletter with market recaps, educational explainers, and honest takes — delivered every Sunday.

Subscribe Free