401(k) Loan Calculator: Repayments and Retirement Cost
Use this guide to understand the assumptions, inputs, results, and next steps behind the calculator.
Created by Luis Gonzalez · Last updated July 29, 2026
A 401(k) loan lets you borrow from your workplace retirement account and repay the balance, usually through payroll deductions. The loan may avoid the income tax and early-withdrawal penalty that can apply to a withdrawal, but it removes money from investments while the loan is outstanding. Use this calculator to estimate payments and compare the repayment cost with possible lost investment growth.
The calculator uses your loan amount, interest rate, loan term, account balance, expected market return, origination fee, and any employer match you might miss while repaying. Its estimates are projections, not guarantees: investment returns vary, and your plan’s loan rules determine what you can borrow and how repayment works.
Start With the Loan Terms
Enter the amount you plan to borrow, the loan’s annual interest rate, and the repayment term. Add your current 401(k) balance to help evaluate the size of the loan relative to your account. The expected market return estimates the growth the borrowed money might otherwise have earned. Include the origination fee and any employer match you expect to forgo.
The calculator’s payment schedule shows each month’s payment divided into principal and interest, plus the remaining balance. If you want to focus on the payment timeline, use the 401(k) Loan Repayment Calculator. For a 403(b) or federal Thrift Savings Plan loan, compare the 403(b) Loan Calculator and TSP Loan Calculator.
How a 401(k) Loan Can Cost More Than Its Interest
Loan interest is generally credited back to your account, but that does not make borrowing cost-free. The borrowed amount may miss investment growth, and repayments may not restore the investments at the same pace or price they would have had without the loan. The loan also adds a fixed payroll deduction that can make it harder to keep contributing enough to receive the full employer match.
Consider a $20,000 loan at 5.5% repaid monthly over five years. The monthly rate is 5.5% ÷ 12 = 0.4583%, and the number of payments is 5 × 12 = 60. The amortizing payment formula gives an approximate payment of $382 per month. Total scheduled payments are about $382 × 60 = $22,920, or approximately $2,920 in interest, before any origination fee. Actual figures may differ because plans can use different payment conventions and round each installment.
Now compare the loan rate with an assumed 7% annual market return. If $20,000 remained invested for five years at a steady 7%, its projected growth would be:
$20,000 × (1.07^5 − 1) = about $8,051
That is a hypothetical comparison, not a guaranteed loss. It assumes the money would earn 7% every year and does not model the timing of repayments back into the account. The calculator’s opportunity-cost estimate should therefore be read as a scenario, not a bill you will owe.
A loan can also affect saving behavior. If payroll deductions cause you to reduce contributions, you may lose some or all of an employer match. Check whether you can keep contributing while repaying. A 401(k) Contribution Calculator can help assess contribution levels, while the 401(k) Paycheck Impact Calculator estimates how a contribution change affects take-home pay.
Federal Loan Rules and Plan Terms
Federal tax law generally limits a plan loan to the lesser of $50,000 or 50% of your vested account balance, with special rules that may allow a small loan when 50% of the vested balance is less than $10,000. A plan can impose stricter limits or offer no loans at all. The IRS explains plan loan limits and repayment rules.
Most plan loans must be repaid within five years, with payments made at least quarterly. A loan used to buy a primary residence may qualify for a longer repayment period if the plan permits it. Interest rates and fees are set under the plan’s terms; ask the plan administrator for the actual rate, repayment schedule, and fees before borrowing. The U.S. Department of Labor describes participant rights and plan information.
Leaving your job can create a repayment deadline or a risk that the outstanding balance will be treated as a distribution. Read the loan agreement for the rules that apply after separation from service. If a loan is not repaid and becomes a taxable distribution, the 401(k) Loan Default Penalty Calculator estimates possible taxes and penalties. For the tax treatment of ordinary withdrawals, see how 401(k) withdrawals are taxed in retirement.
Formula: Monthly Payment and Growth Comparison
The standard fixed-payment formula spreads principal and interest over equal payment periods.
Periodic interest rate = annual interest rate ÷ payments per year
Monthly payment =
loan amount × periodic interest rate × (1 + periodic interest rate)^number of payments
÷ [(1 + periodic interest rate)^number of payments − 1]
For the example, the periodic rate is 5.5% ÷ 12 = 0.004583, and the number of payments is 60. Substituting those values and $20,000 into the formula gives approximately $382 per month.
Total scheduled payments = monthly payment × number of payments
Total interest = total scheduled payments − loan amount
Using the rounded payment: $382 × 60 = $22,920, then $22,920 − $20,000 = about $2,920 in interest. A schedule calculated with unrounded payments will produce a slightly different total.
Projected growth missed =
loan amount × [(1 + expected annual return)^loan term − 1]
At 7% for five years: $20,000 × (1.07^5 − 1) ≈ $8,051. The estimate does not model market volatility, repayment reinvestment, or taxes.
Compare Different Loan Scenarios
These examples vary the loan size, rate, and term. Payments are approximate monthly amortizing payments and exclude fees.
| Loan amount | Annual rate | Term | Approximate monthly payment | Approximate interest over term |
|---|---|---|---|---|
| $10,000 | 5% | 3 years | $299.71 | $789 |
| $15,000 | 6% | 4 years | $352.27 | $1,909 |
| $30,000 | 7% | 5 years | $594.02 | $5,641 |
A longer term generally lowers the required payment but increases total interest and keeps the money out of its original investments longer. A larger loan raises both the payment and the amount exposed to missed growth. Test the smallest amount and shortest affordable term that meet the need rather than borrowing the maximum.
When a Loan May Be a Poor Fit
A 401(k) loan can be risky if your income is unstable, you may change jobs, or the repayment deduction would cause you to stop contributing. Compare its total costs with alternatives such as a lower-cost personal loan, negotiating a payment plan, or using available savings while preserving an emergency reserve. A 401(k) Withdrawal Calculator can help compare a loan with a withdrawal, but withdrawals have different tax consequences.
Do not treat the loan as an investment strategy. Repaying interest to your own account does not guarantee that the borrowed funds would have earned less in the market. To see how contributions and compounding affect a retirement balance, use the 401(k) Compound Interest Calculator or 401(k) Future Value Calculator. If you are reviewing your overall savings plan, compare your results with the 401(k) Calculator and retirement calculator.
Next Steps Before Borrowing
Request the plan’s loan policy and confirm the maximum, interest rate, fees, payment method, and rules if you leave your job. Then test a lower loan amount, a shorter term, and the effect of maintaining your regular contributions. Compare the payment schedule with your monthly budget and review how your balance may grow using the 401(k) Max Contribution Calculator and 401(k) Contribution Calculator.
Frequently Asked Questions
Quick answers to the questions people usually have after running the retirement calculator.
1Does interest on a 401(k) loan go back into my account?
Usually, loan payments—including interest—are credited to your plan account, but this does not eliminate the opportunity cost. The borrowed money may miss market gains or losses, and repayments return over time rather than all at once.
2Is a 401(k) loan better than an early withdrawal?
A loan avoids an immediate taxable distribution if it follows plan and tax rules, but it must be repaid and can become taxable if it defaults. A withdrawal may be taxable and may face a 10% additional tax if you are under 59½, unless an exception applies. Compare both paths with the 401(k) Early Withdrawal Penalty Calculator.
3Can I borrow from a 401(k) if I have another plan loan?
Possibly, but the plan may limit the number of outstanding loans or apply federal limits that account for recent loan balances. Ask the plan administrator how it calculates your available loan amount.
4What happens if I leave my employer with a loan outstanding?
The plan may require repayment or apply its plan-specific procedures. An unpaid balance can become a taxable distribution or loan offset. The 401(k) Loan Default Penalty Calculator can estimate potential consequences, but the administrator must confirm your actual deadline.
5Should I borrow for an emergency or preserve my 401(k)?
That is a tradeoff between immediate liquidity and retirement investment risk. Compare the loan payment with your budget, likely job stability, fees, alternative borrowing costs, and the effect on employer matching. A loan that prevents a costly debt or missed housing payment may be preferable to a high-interest alternative, but it still reduces investment exposure.
6Does repaying the loan count as a 401(k) contribution?
No. Loan repayments are not elective salary deferrals and generally do not count toward the annual employee contribution limit or earn an employer match. Keep regular contributions separate from loan payments.