Finance

How to Calculate Loan Payments: The PMT Formula Explained

Gizmoop Team · 8 min read · May 21, 2026

The monthly loan payment formula is M = P times r times (1 + r) to the power n, all divided by ((1 + r) to the power n minus 1), where P is the loan principal, r is the monthly interest rate, and n is the total number of monthly payments. That single equation drives every fixed-rate installment loan: mortgages, auto loans, personal loans, and student loans all follow the same math. Once you understand what each variable means and how they interact, you can calculate any payment by hand, verify a lender's quote, or model what happens if you change the rate or the term. This guide walks through the formula step by step, works a complete numeric example, and shows you how to replicate the result in any spreadsheet.

The three variables: P, r, and n

Every loan payment calculation starts with the same three inputs. Getting them right is more important than the formula itself, because a small error in any one of them changes the result significantly.

  • P (principal). This is the amount you borrow, not counting any interest. If you take out a 20,000 dollar car loan, P = 20,000. If you are refinancing a mortgage with a remaining balance of 185,000 dollars, P = 185,000. Use the actual loan amount at origination, not the purchase price of the asset.
  • r (monthly interest rate). Lenders quote rates as an annual percentage rate (APR). To use the formula, divide that annual rate by 12. A 6 percent annual rate becomes r = 0.06 divided by 12, which equals 0.005. A 7.2 percent annual rate becomes r = 0.072 divided by 12, which equals 0.006. If your lender quotes a rate of 5.4 percent, r = 0.054 divided by 12 = 0.0045. Always convert the percentage to a decimal before dividing.
  • n (total number of payments). For a monthly loan, n is the loan term in years multiplied by 12. A 5-year loan has n = 60 payments. A 3-year loan has n = 36 payments. A 30-year mortgage has n = 360 payments. If your lender describes the term in months rather than years, you can use that number directly.

Notice that r and n must use the same time unit. Because most loans compound monthly, r is the monthly rate and n is the number of months. If you ever encounter a loan that compounds weekly or daily, you would need to adjust both variables to match that period, but standard consumer loans are always monthly.

The full formula written out

Written in plain words, the formula is:

Monthly payment = Principal times (monthly rate times (1 plus monthly rate) to the power of number of payments) divided by ((1 plus monthly rate) to the power of number of payments minus 1).

The numerator multiplies the principal by a growth factor that accounts for compounding. The denominator converts that growth factor into a fraction that spreads the repayment evenly across all n periods. Together they produce the single fixed payment that, when made every month for n months, pays off exactly P dollars of principal plus all the accumulated interest.

This formula is sometimes called the annuity formula or the amortizing payment formula. It is the same math that underlies a full loan amortization schedule, which shows how each payment splits between interest and principal month by month. The monthly payment stays constant throughout a fixed-rate loan even though the interest-to-principal split shifts with every payment.

Worked example: 20,000 dollars at 6 percent for 5 years

To make the formula concrete, follow this step-by-step calculation for a 20,000 dollar loan at a 6 percent annual interest rate over 5 years.

Step 1: Identify the inputs. P = 20,000. Annual rate = 6 percent, so r = 0.06 divided by 12 = 0.005. Term = 5 years, so n = 5 times 12 = 60.

Step 2: Calculate (1 + r) to the power n. (1 + 0.005) to the power 60 = (1.005) to the power 60. Using a calculator: 1.005 raised to the 60th power equals approximately 1.34885.

Step 3: Build the numerator. P times r times (1 + r) to the power n = 20,000 times 0.005 times 1.34885 = 20,000 times 0.0067443 = 134.885.

Step 4: Build the denominator. (1 + r) to the power n minus 1 = 1.34885 minus 1 = 0.34885.

Step 5: Divide. 134.885 divided by 0.34885 equals approximately 386.66.

The monthly payment is about 386.66 dollars. Over 60 payments you will pay 60 times 386.66, which equals 23,199.60 dollars. Subtracting the 20,000 dollar principal, the total interest paid over the life of the loan is approximately 3,199.60 dollars, or roughly 3,200 dollars. Every penny of that interest is a direct result of holding the balance over time, which is why paying down principal early reduces total interest so powerfully.

Payment vs. total paid vs. total interest

These three figures tell you different things about a loan, and confusing them is one of the most common mistakes borrowers make when comparing offers.

  • Monthly payment is the fixed amount you owe each month. It is the direct output of the PMT formula. A lower monthly payment feels affordable, but it does not tell you the full cost.
  • Total paid is the monthly payment multiplied by the number of payments. For the worked example: 386.66 times 60 = 23,199.60 dollars. This is the total cash that leaves your account over the life of the loan.
  • Total interest is total paid minus the original principal: 23,199.60 minus 20,000 = 3,199.60 dollars. This is the true cost of borrowing. Two loans with the same monthly payment can have very different total interest figures if one has a shorter term.

When evaluating loan offers, always compare total interest rather than just the monthly payment. A lender who stretches your term from 48 months to 60 months can reduce your monthly payment by 70 dollars while adding hundreds of dollars to your total interest bill. The loan calculator below shows all three figures instantly for any set of inputs.

The zero-interest special case

When the interest rate is zero, the standard PMT formula produces a division by zero error because the denominator becomes (1 + 0) to the power n minus 1 = 1 minus 1 = 0. For a zero-interest loan the calculation is simply the principal divided by the number of payments.

For example, a 12,000 dollar interest-free financing offer over 24 months has a monthly payment of 12,000 divided by 24 = 500 dollars exactly. No formula needed. Retailers and automakers occasionally offer genuine zero-percent promotional financing for qualified buyers, and this simpler rule applies for as long as the zero rate is in effect.

How to calculate a loan payment in a spreadsheet

Spreadsheets have a built-in PMT function that does the same calculation in one step. The syntax is identical in Excel, Google Sheets, and LibreOffice Calc.

The function is: =PMT(rate, nper, pv)

  • rate is the periodic interest rate. For a monthly loan, enter the annual rate divided by 12. You can type the formula directly: for a 6 percent annual rate, enter 6%/12 or 0.06/12.
  • nper is the total number of payments. For a 5-year monthly loan, enter 60 or 5*12.
  • pv is the present value, meaning the loan amount. Enter it as a positive number: 20000.

For the worked example, the full cell formula is =PMT(0.06/12, 60, 20000), which returns approximately negative 386.66. The negative sign means this is a cash outflow. To display the payment as a positive number, either wrap the function in ABS() or negate the principal: =PMT(0.06/12, 60, -20000) returns positive 386.66.

If you want to build a full amortization schedule alongside the payment, each row's interest column is the previous remaining balance times r, and each row's principal column is the payment minus that month's interest. The balance column decrements by the principal column each row and reaches zero exactly at payment n. The loan amortization guide shows how to structure that table in full.

How rate and term change the payment

The table below shows how the monthly payment on a 20,000 dollar loan changes across different interest rates and loan terms. All figures are rounded to the nearest cent. Notice how a higher rate has a larger effect at longer terms, because there are more months over which the compounding works against you.

Annual rate24 months36 months48 months60 months72 months
0%$833.33$555.56$416.67$333.33$277.78
3%$859.01$581.62$442.56$359.37$303.68
5%$877.43$599.42$460.59$377.42$322.10
6%$886.64$608.44$469.70$386.66$331.39
8%$904.16$626.73$488.26$405.53$350.67
10%$921.82$645.34$507.25$424.94$370.52
12%$939.58$664.29$526.68$444.89$390.97

Two patterns stand out in this table. First, doubling the term does not halve the payment when the rate is above zero, because the extra months add interest. Compare the 6 percent row: the 24-month payment is 886.64 dollars while the 72-month payment is 331.39 dollars, a reduction of about 63 percent, not 75 percent. The interest compounding eats into the savings from the longer term. Second, the payment difference between a low rate and a high rate grows as the term lengthens. At 24 months the gap between 3 percent and 12 percent is about 80 dollars per month; at 72 months that gap widens to about 87 dollars. Small rate differences matter more when you carry a balance for longer.

Calculate your loan payment now

Enter your loan amount, annual interest rate, and term in months to see your exact monthly payment, total amount paid, and total interest. Adjust any input to compare scenarios instantly.

$
%
years
Monthly payment
$2,052
Total interest
$23,099
Total amount paid
$123,099

Why the formula produces a fixed payment

It might seem surprising that the same dollar amount every month can pay off both a variable interest charge and a growing slice of principal simultaneously. The key is that the interest charge is not fixed: it shrinks with every payment because the remaining balance shrinks. In the early months of the worked example, about 100 dollars of the 386.66 dollar payment goes to interest and about 287 dollars goes to principal. By month 59 the interest portion is less than 2 dollars and almost the entire payment reduces the remaining balance.

This gradual shift is called amortization, and the mathematical elegance of the PMT formula is that it sets the payment at exactly the right level so that both slices always add up to the same number and the balance reaches zero on the last scheduled payment. Choosing a higher payment (by selecting a shorter term) accelerates the principal paydown and therefore reduces the interest charged in every subsequent month, which is the core mechanism behind paying off a loan early.

What the formula does not include

The PMT formula calculates the pure interest-plus-principal payment. A real loan statement may include additional charges that raise your actual monthly outlay above the formula result.

  • Loan origination fees. Some lenders add a one-time percentage fee at closing. This may be rolled into the principal (increasing P) or paid upfront. If it is rolled in, the formula still works but you must use the higher principal.
  • Mortgage insurance or PMI. On home loans with a down payment below 20 percent, lenders often require private mortgage insurance. This adds a monthly premium on top of the PMT result.
  • Property taxes and homeowner's insurance. Many mortgage servicers collect these via an escrow account as part of the monthly payment. They are separate from the loan math.
  • Gap insurance and add-on products. Auto lenders may bundle optional products into the financed amount. If they are rolled into the loan, they increase P and therefore the calculated payment.

For a clean comparison between loan offers, always strip out add-on fees and compare the PMT result on the base principal and rate. The annual percentage rate (APR) disclosure required by US lending law is designed to help with this comparison by folding certain fees into a single annual rate figure.

Putting it all together

Calculating a loan payment is a three-step process: convert the annual rate to a monthly rate by dividing by 12, convert the term to months by multiplying years by 12, then plug P, r, and n into the formula. For almost every practical situation you can use the spreadsheet PMT function or the loan calculator on this page rather than solving the algebra by hand. The hand calculation is worth doing once so that the formula feels familiar and you can spot-check any quote a lender gives you.

Once you have the monthly payment, multiply by n to get total paid, then subtract the principal to find total interest. That single number, total interest, is the truest measure of what a loan costs you and the most useful figure for comparing two offers side by side. A loan with a slightly higher monthly payment but a much lower total interest figure is almost always the better deal over the full term.

Frequently asked questions

Answers to the most common questions about the loan payment formula, the PMT function, and how rate and term affect what you owe each month.

PMT stands for payment. It is the standard abbreviation used in finance and in spreadsheet software (Excel, Google Sheets, LibreOffice Calc) for the periodic payment amount on a loan or annuity. When you see the PMT formula in a textbook or a spreadsheet function, it refers to the fixed monthly payment that pays off both the interest and a portion of the principal on every scheduled date.

In the formula M = P times r times (1 + r) to the power n, divided by ((1 + r) to the power n minus 1), the variable r is the periodic interest rate. For a standard monthly loan, r is the annual percentage rate divided by 12. For example, a 6 percent annual rate gives r = 0.06 divided by 12, which equals 0.005. If your loan compounds more or less frequently than monthly, you would adjust the division accordingly, but almost all personal and auto loans compound monthly.

A longer term spreads the same principal across more payments, so each individual payment is smaller. However, interest accrues on the outstanding balance every month. The more months you carry a balance, the more total interest accumulates, even though the rate is identical. On a 20,000 dollar loan at 6 percent, extending from 48 months to 72 months saves about 72 dollars per month but adds roughly 1,000 dollars in total interest paid over the life of the loan. The monthly payment is lower, but the total cost is higher.

Use the built-in PMT function. The syntax is =PMT(rate, nper, pv) where rate is the monthly interest rate (annual rate divided by 12), nper is the total number of payments, and pv is the present value (the loan amount as a positive number, or the formula will return a negative result unless you negate it). For the worked example in this article, the formula is =PMT(0.005, 60, 20000), which returns approximately negative 386.66. The negative sign reflects a cash outflow; take the absolute value for the payment amount.

If the interest rate is zero, the standard PMT formula breaks down because dividing by zero is undefined. For a zero-interest loan the calculation is simply the principal divided by the number of payments. A 12,000 dollar interest-free loan over 24 months has a payment of exactly 500 dollars per month. Some lenders and retailers offer promotional zero-percent financing, and this simpler rule applies for the duration of the zero-rate period.

Yes, provided you enter the same inputs. The loan calculator on this page uses the identical PMT formula internally. Small differences of a cent or two can appear due to how each tool rounds intermediate steps, but both methods produce the same payment to the nearest dollar. For most practical purposes the results are identical. If you see a larger discrepancy, check that you are using the same annual rate, the same term in months, and the same loan amount in both places.

See your exact payment in seconds

Run any loan scenario in the free Loan Calculator, or browse more finance and everyday-math articles.