Pay off the loan early or invest? An Excel comparison

This is not tax, legal, or lending advice. The sheet compares two uses of the same monthly cash. It is not a payoff quote and not an investment forecast.

The loan is the $320,000 sample at 6.25% for 30 years. The first payment on that sample is January 15, 2026, and the scheduled payment displays as $1,970.30. The unrounded payment is about 1,970.295041. Nothing extra, the loan runs 360 months and the interest is $389,306.21. Those figures are the ones on the loan payoff calculator page.

That page also adds a $1,000 lump sum on payment 12. With the $200 and the lump sum together, the balance reaches zero on payment 280 and the interest is $287,247.25, which is $102,058.96 less than the plain path. This page leaves the lump sum out, so the comparison is the $200 alone.

The workbook is the loan payoff calculator.

Year 1 on the plain loan

CUMIPMT adds the interest from one period to another. Periods 1 through 12 are the first year. The last argument is 0, which means the payment is due at the end of the month. Leave that argument out and the result is #NUM!.

CUMIPMT
=CUMIPMT(B1/12,B2*12,-B3,1,12,0)
=CUMIPMT(B1/12,B2*12,-B3,1,12,0)B4
Year 1 interest on the plain loan
AB
1Rate6.25%
2Years30
3Principal$320,000
4Year 1 interest$19,893.79
A picture of the $320,000 sample. The rate is 6.25% and the term is 30 years. Year-1 interest displays as $19,893.79. The unrounded total is about 19,893.7943.

The amount borrowed is negative so the interest comes back positive, which is the sign on the CUMIPMT page. After 12 payments, xl.loan.balance is:

=xl.loan.balance(6.25%, 360, 320000, 12)

The balance displays as $316,250.25. The unrounded balance is about 316,250.2538. The name needs Microsoft 365, Excel 2024, or Excel for the web. Excel 2021 returns #NAME? for LAMBDA. The same balance without the name is the principal grown for 12 months, minus the payments grown to that date.

The extra $200 ends the loan in month 282

NPER asks how many payments of a fixed size it takes to bring the balance to zero.

NPER
=NPER(B1/12,-(B4+B5),B3)
=NPER(B1/12,-(B4+B5),B3)B6
Months until the extra $200 finishes the loan
AB
1Rate6.25%
2Months360
3Principal$320,000
4Payment$1,970.30
5Extra$200
6Months left281.1995
A picture with no cent rounding and no $1,000 lump sum. The payment displays as $1,970.30. Plus $200, the budget displays as $2,170.30. NPER stores about 281.19947.

The stored result is about 281.19947. A two-decimal number format shows 281.20. That is not 281 full payments and then a stop. After 281 payments of the full budget, the balance is still $431.56. Month 282’s interest on that balance is about $2.25, so the last check is $433.81, and the balance is zero. The interest along that path, with no cent rounding, is $290,286.72. Against the plain path’s $389,306.21, the interest avoided is $99,019.50.

Each month’s interest in that total is the opening balance times 0.0625 divided by 12. A lender that counts actual days will differ by a few dollars.

The same cash at the sample 5%

The monthly cash is the same on both paths. Through month 281 it is the scheduled payment plus $200. On the invest path the $200 goes to savings and the payment goes to the lender. On the payoff path the whole budget goes to the lender.

The savings rate is the 5% sample on the FV page, not a rate from a market quote. Pass the deposit as a negative number so the balance comes back positive.

FV
=FV(B1/12,B2,-B3)
=FV(B1/12,B2,-B3)B5
Where the same monthly cash sits at month 360
AB
1Savings rate5%
2Months360
3Extra$200
4
5Invest path$166,451.73
6Payoff path$201,945.48
A picture of the sample 5% from the FV page. B5 is $200 a month for 360 months. B6 grows the $1,736.48 left over in month 282 for 78 months and then adds 78 deposits of the full budget.

The invest path holds $166,451.73 at month 360, and the loan has been paid on the original 360-month schedule.

On the payoff path the loan is gone in month 282. That month’s budget displays as $2,170.30 and the last loan check is $433.81, so $1,736.48 is left to invest. Then months 283 through 360 are 78 deposits of the full budget, still at 5%. At month 360 that account displays as $201,945.48.

The difference between those two displayed balances is $35,493.75. The payoff path is ahead on this pair of rates. A savings rate above 6.25%, or a tax deduction on the mortgage interest, can close that gap or reverse it. The sheet does not compute either one.


Template for this article

Loan Payoff Calculator

More from the blog