Home › Calculators › 401(k) Loan Calculator

401(k) Loan Calculator

Plan a loan from your 401(k). Enter your vested balance, loan amount, rate and term to see the payment for your pay schedule, the maximum the IRS lets you borrow, the interest you pay back into your own account and the investment growth you miss while the money is out.

Last updated:

Your 401(k)
$

Only the vested part counts toward the limit.

$

Reduces the $50,000 cap. 0 if none.

Loan
$
%

Most plans charge prime + 1%.

years

Up to 5 years; longer allowed for buying a main home.

Opportunity cost
%

What the borrowed money would have earned in the market.

Enter your values to see the result.
Advertisement
Advertisement

How to use the 401(k) Loan Calculator

  1. Enter your vested 401(k) balance and any loan balance you had in the last 12 months.
  2. Enter the loan amount, rate and term. Plans usually charge prime + 1% for up to 5 years.
  3. Pick how often you are paid, since repayments come out of each paycheck.
  4. Set an expected investment return to measure the growth you give up.
  5. Read the payment, maximum loan, interest and lost growth, then check the yearly schedule.

401(k) loan rules at a glance

RuleLimit (IRC section 72(p))
Maximum loanLesser of $50,000 or 50% of vested balance (up to $10,000 allowed when 50% is less)
Prior loans$50,000 is reduced by the highest outstanding loan balance during the past 12 months
Term5 years for general loans; longer for buying a principal residence
PaymentsLevel amortization, at least quarterly (usually every paycheck)
Interest rateSet by the plan, commonly the prime rate + 1%
DefaultMissed payments past the cure period become a taxable deemed distribution

How the opportunity cost is measured

The calculator follows two versions of your account until the loan is paid off:

  • Without the loan: the whole vested balance grows at your expected return.
  • With the loan: the balance minus the loan grows at that return, and each payroll repayment (principal + interest) is deposited back and starts growing. The outstanding loan is counted as an asset of the account.

The difference at payoff is the growth you give up. When markets return less than the loan rate, the gap can be negative, meaning the loan actually came out ahead. Future contributions are left out of both versions, because they are the same either way, unless you stop contributing while repaying, which makes the real cost higher.

Biweekly payment per $10,000 borrowed

Rate1 year3 years5 years
7%$398.75$142.31$91.27
8%$400.80$144.40$93.45
9%$402.85$146.51$95.66

Payment uses 26 payments a year: P = 10,000 × r ÷ (1 − (1 + r)−n) with r = rate ÷ 26.

Tips before you borrow

  • Keep contributing while you repay so you don't lose your employer match.
  • Borrow only what you need and pick the shortest term you can afford.
  • Think about job security: leaving or losing your job can make the balance due quickly.
  • If you can't repay, compare the cost of a withdrawal with the 401(k) early withdrawal calculator.

Frequently asked questions

How much can I borrow from my 401(k)?

Federal rules cap a 401(k) loan at the lesser of $50,000 or 50% of your vested balance. If half your balance is under $10,000, a plan may let you borrow up to $10,000. The $50,000 cap is reduced by your highest outstanding loan balance in the past 12 months. Your plan can set lower limits or not offer loans at all.

How is the 401(k) loan payment calculated?

It is a standard amortizing payment: P = L × r ÷ (1 − (1 + r)^−n), where L is the loan, r is the yearly rate divided by the number of paychecks a year, and n is the total number of paychecks in the term. Payments must be at least quarterly and are normally taken by payroll deduction.

Do I pay interest to myself?

Yes. The interest goes back into your own 401(k) account, not to a bank. However, you repay it with after-tax pay, and that money is taxed again when you withdraw it in retirement.

What is the real cost of a 401(k) loan?

The main cost is opportunity cost. The borrowed money is out of the market and only earns the loan rate. If investments return more than the loan rate during the loan, your account ends up smaller than it would have been. The calculator shows that gap at payoff.

What happens if I leave my job with a 401(k) loan?

Most plans require the remaining balance to be repaid when you leave. If you don't, the unpaid amount becomes a loan offset distribution: it is taxed as income and, before 59½, may get the 10% penalty. You have until your tax return due date, including extensions, to roll that amount into an IRA to avoid the tax.

How long can a 401(k) loan last?

General-purpose loans must be repaid within 5 years. Loans used to buy your main home can have a longer term set by the plan, often 10 to 15 years or more.

Is a 401(k) loan better than a withdrawal?

Usually, if you can repay it. A loan has no tax or penalty when repaid on time, while an early withdrawal is taxed as income and often penalized 10%. Compare both with the 401(k) early withdrawal calculator.

Are all the tools on FreeToolCabin tested for quality and accuracy?

Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.

Related tools

401(k) Early Withdrawal CalculatorSee the 10% penalty, taxes, cash you keep and lost growth from cashing out a 401(k) early.401(k) CalculatorProject your 401(k) balance with employer match and growth.Loan CalculatorMonthly payments and amortization for loans and mortgages.401k Employer Match CalculatorWork out your 401k employer match, total contribution, vesting and match left on the table.Mortgage CalculatorMonthly mortgage payment with taxes, insurance, PMI and HOA, plus a yearly amortization schedule.PMI CalculatorMonthly PMI, loan-to-value and the month PMI drops off at 80% or 78% LTV.Mortgage Refinance CalculatorCompare your current and new mortgage, break-even month and savings.Extra Mortgage Payment CalculatorSee how extra payments cut your mortgage term and interest.Rent vs Buy CalculatorCompare the long-run cost of renting versus buying a home.Car Loan CalculatorMonthly car payment with down payment, trade-in, APR and amortization.Mortgage Affordability CalculatorHow much house you can afford from income, debts and DTI limits.Debt Payoff CalculatorCompare debt snowball vs avalanche: payoff date and interest saved.APR CalculatorFind a loan's true APR including fees, the monthly payment and APR to APY conversions.Personal Loan CalculatorMonthly payment, total cost and true APR of a personal loan, including the origination fee.Amortization CalculatorMonth-by-month loan amortization schedule with yearly totals and an extra payment option.Student Loan CalculatorFind your student loan payment, total interest and how extra payments shorten payoff.Car Lease CalculatorCalculate a monthly car lease payment with depreciation, finance fee, residual and tax.Down Payment CalculatorSee your home down payment, loan, monthly payment, PMI and how long it takes to save.Debt-to-Income Ratio CalculatorCalculate front-end and back-end debt-to-income ratio and compare with lender limits.HELOC CalculatorAvailable home equity credit line plus interest-only and repayment-period HELOC payments.Mortgage Payoff CalculatorNew payoff date, time saved and interest saved with extra or lump-sum mortgage payments.Biweekly Mortgage CalculatorCompare monthly and biweekly mortgage payments: interest saved, years saved and payoff date.Mortgage Points CalculatorIs buying discount points worth it? Cost, monthly savings, break-even month and net savings.Closing Cost CalculatorEstimate itemized closing costs, prepaids and total cash to close for a home purchase.Rent Affordability CalculatorHow much rent you can afford with the 30% rule, the 40x income rule and your debts.Loan Comparison CalculatorCompare up to three loans: monthly payment, total interest, fees, total cost and APR.Balloon Payment CalculatorMonthly payment and lump-sum balloon due on an amortizing or interest-only loan.Business Loan CalculatorBusiness loan payments (monthly, weekly or daily), total cost and effective APR with fees.Loan-to-Value CalculatorLTV, CLTV and HCLTV ratios, home equity, and the pay-down needed to drop PMI.Credit Card Payoff CalculatorSee when your card is paid off, the interest you pay, and how it compares with the minimum.Debt Snowball CalculatorPlan payoff of several debts: snowball vs. avalanche order, debt-free date and interest saved.Car Affordability CalculatorSee how much car you can afford with the 20/4/10 rule or your monthly budget.Sleep Debt CalculatorFind your weekly sleep debt from hours slept per night and get a simple recovery plan.15 vs 30 Year Mortgage CalculatorCompare 15- and 30-year mortgages: payment, total interest and equity built side by side.Adjustable Rate Mortgage CalculatorARM payments after each rate reset, worst case under the caps, and interest vs a fixed loan.Balance Transfer CalculatorInterest saved by a 0% balance transfer, balance left at promo end and payoff time.Boat Loan CalculatorMonthly boat payment with down payment, trade-in, tax and fees, plus a yearly amortization table.Cash Out Refinance CalculatorMax cash out at your lender's LTV limit, the new loan and payment, and the break-even point.Bridge Loan CalculatorBridge loan size from home equity, fees, interest-only payments and cash for your next home.Buy Now Pay Later CalculatorTrue cost of pay-in-4 and financed BNPL plans with interest, fees, late fees and APR.True Cost of Homeownership CalculatorReal monthly cost of owning a home: mortgage, tax, insurance, HOA, upkeep and lost returns.Debt Settlement CalculatorNet savings from settling debt after fees, added interest and tax on forgiven debt.Equipment Loan CalculatorEquipment financing payment with down payment, balloon, total interest and Section 179 savings.Hard Money Loan CalculatorFix-and-flip loan size from LTC and ARV, points, interest-only payment and total finance cost.Land Loan CalculatorMonthly payment, balloon and schedule for raw, unimproved or improved land.Equipment Lease vs Buy CalculatorCompare leasing vs buying equipment after tax: payments, depreciation, resale and NPV.Merchant Cash Advance CalculatorTurn an MCA factor rate and holdback into total payback, term and true APR.Pay Off Mortgage or Invest CalculatorExtra principal or invest it? Interest saved vs portfolio growth after tax, year by year.Pay Off Debt or Invest CalculatorExtra cash each month: pay down a loan or invest it? Compare net worth after taxes.ROIC CalculatorReturn on invested capital from NOPAT, debt, equity and cash, compared against WACC.SBA Loan CalculatorSBA 7(a) and 504 monthly payments from prime + spread, with guarantee fee and schedule.USDA Loan CalculatorUSDA mortgage payment with the 1% guarantee fee financed and the 0.35% annual fee.Commercial Mortgage CalculatorCommercial real estate loan payment, balloon at maturity, DSCR, LTV and max loan size.Points & Miles Value CalculatorFind the cents-per-point value of a points or miles redemption and compare it to cash back.HELOC vs Cash-Out Refinance CalculatorCompare a HELOC with a cash-out refinance: payments, closing costs and total cost over time.Mortgage Escrow CalculatorMonthly escrow for taxes and insurance, RESPA cushion, and shortage or surplus over 12 months.Mortgage Interest Deduction CalculatorDeductible mortgage interest under the loan limit, itemize vs standard and tax savings.Net Effective Rent CalculatorTrue monthly rent after free months, move-in credits and concessions over the lease term.Piggyback Loan Calculator (80/10/10)Compare an 80/10/10 first + second mortgage with one loan plus PMI: payment and total cost.Public Service Loan Forgiveness CalculatorEstimate your PSLF forgiveness date and amount from payments made, IDR payment, balance and rate.Seller Financing CalculatorOwner-financed payment, balloon amount, seller interest income and a yearly note schedule.Student Loan Capitalized Interest CalculatorInterest accrued in school, grace and deferment, your capitalized balance and new payment.0% APR Payoff CalculatorMonthly payment to clear a 0% purchase before the promo ends, and the deferred interest at risk.Construction Loan CalculatorDraw schedule, interest-only payments during the build and the permanent loan payment.Credit Card Minimum Payment CalculatorHow long minimum payments take to clear a card, total interest and the full schedule.Credit Card Processing Fee CalculatorCard processing fees, your net, and the surcharged price that keeps the full sale.Debt Avalanche CalculatorPay off debts highest APR first: payoff dates, total interest and savings vs snowball.Debt Consolidation CalculatorCompare your debts with a consolidation loan: payment, interest, fees and net savings.
See all 84 Loan & Mortgage Calculators →