Example 1
Months to repay a loan
B4 =ROUND(NPER(B2/12,-B3,B1),2)
Result: 43.85
The payment is negative because it is cash out. It takes 43.85 months, which means 43 full payments and a smaller 44th.
B4 =ROUND(NPER(B2/12,-B3,B1),2) returns 43.85
Returns the number of periods needed to repay a loan or reach a savings goal, for a constant payment and interest rate.
Syntax
=NPER(, , , , )
All versions of Excel.
Try it
Edit the formula in B4 or change the inputs. The sheet recalculates as you type.
B4 =ROUND(NPER(B2/12,-B3,B1),2) returns 43.85
NPER answers "how long will it take?". It returns the number of payment periods needed to clear a loan or build a balance when the rate and payment stay constant. =NPER(5%/12,-500,20000) returns 43.85: paying 500 a month on a 20,000 loan at 5% a year takes about 43.85 months. The periods are in whatever unit your rate uses, so for a monthly rate the answer is in months.
Excel treats money you receive as positive and money you pay as negative. A loan you receive is positive, and the payments are cash out, so enter them as negative: -500. If pv and pmt have the same sign, there is no solution, and NPER returns a wrong or unusable result, often #NUM!. For savings, the deposits are negative and the target balance is positive: =NPER(4%/12,-300,0,50000) returns about 132.8 months.
#NUM!.NPER returns the exact number of periods, which is usually a fraction, because the last payment is smaller. For a whole number of payments, round up: =ROUNDUP(NPER(5%/12,-500,20000),0) is 44. The 44th payment is smaller than 500. Divide by 12 for years: =NPER(...)/12.
=ROUNDUP(NPER(rate/12,-payment,balance),0).=NPER(rate/12,-deposit,0,goal)/12.=EDATE(TODAY(),ROUNDUP(NPER(rate/12,-payment,balance),0)).=NPER(rate,0,-1,2) for a rate per year.NPER is the "n" in the financial five: PMT finds the payment, PV the loan, FV the future balance, RATE the rate. Each takes the same arguments, so you can solve for whichever is unknown.
NPER assumes a constant rate and equal payments. It ignores fees and changes in rate.
5%/12.-500. It must be large enough to cover the interest.0, for a loan that is fully repaid. For a savings goal, enter the target as a positive number and set pv to 0.0 or omitted: payments are made at the end of each period. 1: payments are made at the start of each period.Each example is a live sheet. Change the inputs or the formula and watch the result.
Example 1
B4 =ROUND(NPER(B2/12,-B3,B1),2)
Result: 43.85
The payment is negative because it is cash out. It takes 43.85 months, which means 43 full payments and a smaller 44th.
B4 =ROUND(NPER(B2/12,-B3,B1),2) returns 43.85
Example 2
B4 =ROUNDUP(NPER(B2/12,-B3,B1),0)
Result: 44
ROUNDUP turns 43.85 into 44 payments, because you can't make a part payment on the calendar.
B4 =ROUNDUP(NPER(B2/12,-B3,B1),0) returns 44
Example 3
B4 =ROUND(NPER(B2/12,-B3,0,B1),1)
Result: 132.8
Present value is 0 and the future value is the goal. The deposit is negative. 132.8 months is about 11 years.
B4 =ROUND(NPER(B2/12,-B3,0,B1),1) returns 132.8
Example 4
B4 =IFERROR(NPER(B2/12,-B3,B1),"Payment too low")
Result: Payment too low
Interest on 20,000 at 5% is about 83 a month, so a payment of 50 never reduces the balance. NPER returns #NUM!, which IFERROR replaces with a message.
B4 =IFERROR(NPER(B2/12,-B3,B1),"Payment too low") returns Payment too low
Solve it in the sheet. Every answer is checked, with hints if you need them.
Task 1 of 2
In B5, return the exact number of months needed to repay the loan.
Answer in B5.
pmt and pv the same sign. A loan received is positive, and payments made are negative. With matching signs the result is wrong or an error.#NUM!, because the balance never falls. Check the payment first, or wrap the formula in IFERROR.Use `=NPER(annual_rate/12, -payment, loan)`. Round up with ROUNDUP for a whole number of payments.
Most often the payment doesn't cover the interest, or the signs of pmt and pv are the same. Raise the payment or check the signs.
Use `=NPER(rate/12, -deposit, 0, target)`. The result is in months. Divide by 12 for years.
NPER gives the exact length, and the last payment is smaller than the others. 43.85 means 43 full payments and a smaller 44th.
Yes. Use the yearly rate and yearly payment, and the answer is in years.
NPER is taught in Dates and financial modelling, lesson 12: CAGR and doubling time. Each lesson is a short, graded exercise like the one above.