Mortgage Payment Formula: How to Calculate Your Monthly Payment

Published by the MetriqaHub Editorial Team on November 3, 2026.

Mortgage Payment Formula: How to Calculate Your Monthly Payment

Mortgage Payment Formula: How to Calculate Your Monthly Payment

Homeowner calculating a monthly mortgage payment

The monthly principal-and-interest payment on a fixed-rate mortgage is M = P × [r(1 + r)^n] / [(1 + r)^n − 1]. Here P is the loan amount, r is the monthly interest rate (the annual rate divided by 12), and n is the number of monthly payments (years × 12). For a $300,000 loan at 7% over 30 years, that works out to $1,995.91 a month. Below you will find each variable explained, the calculation done by hand, an amortization schedule, and the algebra behind the formula.

TL;DR

Table of Contents

The mortgage payment formula

The formula comes from the present value of an annuity: a level payment made every month that exactly pays off a loan. OpenStax's finance textbook shows that loan payments use the annuity formula, adjusted for monthly periods by dividing the annual rate by 12 and multiplying the years by 12.

Written out:

M = P × [ r(1 + r)^n ] / [ (1 + r)^n − 1 ]

If you prefer a form without the big fraction, it is the same thing as:

M = P × r / [ 1 − (1 + r)^(−n) ]

Both give identical results. The second is easier to type into a basic calculator because you only compute the power once.

What each variable means

SymbolMeaningHow to get it
MMonthly principal-and-interest paymentThe answer
PPrincipal, the amount you borrowPurchase price minus down payment
rMonthly interest rateAnnual rate as a decimal ÷ 12 (7% = 0.07 ÷ 12 = 0.005833)
nNumber of paymentsYears × 12 (30 years = 360)
Principal is the amount you borrowed, and interest is what the lender charges for lending it. The Consumer Financial Protection Bureau explains that your total payment may also include mortgage insurance, homeowners insurance and taxes. The formula above covers only the first two pieces.

The most common mistake is leaving the rate as a yearly figure. If you plug in 0.07 instead of 0.005833, the answer is meaningless. The second most common is mixing years and months: r must be monthly whenever n counts months.

How to calculate a mortgage payment step by step

Here is the full process for a $300,000 loan at 7% for 30 years.


Rounding the intermediate figures shifts the answer by a few cents, so keep as many decimals as your calculator allows until the last step. In a spreadsheet, the same result comes from =-PMT(7%/12, 360, 300000).

A second worked example from a textbook

OpenStax works through a smaller loan: $140,000 financed for 20 years at 3.6% a year. Here r = 0.003 and n = 240, which gives a payment of about $819.16. It is a good test case if you want to check your own arithmetic against a published answer.

Quick reference for common loan sizes

These figures use the same formula, a 30-year term and a 7% fixed rate. They cover principal and interest only.

Loan amountMonthly principal and interest
$200,000$1,330.60
$300,000$1,995.91
$400,000$2,661.21
This also answers a common question: a $400,000 mortgage at 7% for 30 years is about $2,661 a month before taxes and insurance. Because the payment scales in direct proportion to the loan, you can find any other amount by multiplying: $1,000 borrowed at 7% over 30 years costs about $6.65 a month.

How the amortization schedule works

An amortization schedule is a table that shows, payment by payment, how much goes to interest, how much goes to principal, and what balance remains. Your payment stays the same on a fixed-rate loan, but the split changes every month.

The rules are simple. Per the eCampusOntario finance text, interest equals the previous balance times the periodic rate, and principal equals the payment minus interest. Those formulas need the prior balance, and they assume payment and compounding frequencies match.

In symbols:


Amortization schedule example

For the $300,000, 7%, 30-year loan with a payment of $1,995.91:

MonthPaymentInterestPrincipalRemaining balance
1$1,995.91$1,750.00$245.91$299,754.09
2$1,995.91$1,748.57$247.34$299,506.75
3$1,995.91$1,747.12$248.79$299,257.96
Month 1 interest is $300,000 × 0.0058333 = $1,750.00. That leaves $245.91 to reduce the loan. In month 2 the balance is a little lower, so the interest charge is a little lower, and slightly more of the same payment goes to principal. Repeat that 360 times and the balance reaches zero.

OpenStax's textbook schedule for its $140,000 loan shows the same pattern at a smaller scale. Month 1 is $420.00 interest and $399.16 principal, and month 240 is $2.45 interest and $816.71 principal, with a small rounding adjustment in the final line. That is front-loading in action: declining balances shrink the interest charge, so a growing share of the unchanged payment pays down principal.

Mortgage payment split shifts from interest to principal

Total interest over the life of the loan

Multiply the payment by the number of payments, then subtract the principal:

Total interest = (M × n) − P

For our example: ($1,995.91 × 360) − $300,000 = $718,527.60 − $300,000 ≈ $418,528. On a 30-year loan at 7%, you pay more in interest than you borrowed. That is why term and rate matter so much, and why many borrowers look at what extra payments can save.

Why early payments are mostly interest

Interest is charged on what you still owe. At the start you owe everything, so interest is at its peak. In the example above, about 88% of the first payment is interest ($1,750.00 of $1,995.91). Only a small slice reduces the loan.

The balance falls slowly at first, then faster. In the middle of the schedule the split is roughly even, and in the last few years nearly the entire payment is principal. This is what lenders mean when they describe a fixed-rate loan as predictable: the payment never changes, even though its internal makeup does.

Two practical consequences follow:


Deriving the formula

If you want to see where the formula comes from (a frequent request from students), the derivation takes five lines.

Let B₀ = P be the starting balance. Each month, interest is added and the payment is subtracted:

B₁ = B₀(1 + r) − M

B₂ = B₁(1 + r) − M = B₀(1 + r)² − M(1 + r) − M

After n payments:

Bₙ = P(1 + r)^n − M[(1 + r)^(n−1) + … + (1 + r) + 1]

The bracket is a geometric series, which sums to [(1 + r)^n − 1] / r. So:

Bₙ = P(1 + r)^n − M × [(1 + r)^n − 1] / r

A loan is paid off when Bₙ = 0. Set the expression to zero and solve for M:

M = P × r(1 + r)^n / [(1 + r)^n − 1]

That is the formula. It simply says: pick the payment that makes the balance land exactly on zero after n months.

Deriving the formula

What the formula does not include

The result is principal and interest only. The CFPB notes that the amount you send your mortgage company often includes homeowners' insurance and taxes on top of the loan payment. A fuller picture looks like this:

Total monthly payment = principal + interest + mortgage insurance (if applicable) + property taxes and homeowners insurance (if collected in escrow)

To estimate the full figure, calculate M with the formula, then add one-twelfth of your annual property tax bill and one-twelfth of your annual insurance premium. Ask your lender or servicer for exact amounts, since both vary by property and location.

Adjustable-rate and balloon loans

The formula assumes one fixed rate for the whole term. Other loan types differ, according to the same CFPB page:


Perspective

We built our mortgage tools around one belief: you should be able to see the math, not just receive an answer. The formula looks intimidating, but it only has three inputs, and once you have done one example by hand, every lender quote becomes easier to read.
>
That is why our calculators run on the standard annuity math described in finance textbooks, return results instantly, and need no registration. We want you to use the calculator to check your own work, or use the formula to check the calculator. Either way, you end up understanding the number you are about to commit to for 15 or 30 years.
>
Our advice: run your loan at two or three rates and two terms before you talk to a lender. Seeing how a quarter-point or a 15-year term changes the payment and the total interest is the most useful hour of mortgage prep you can spend.
>
Nkosi

Check your own numbers

Doing the math once by hand is the best way to learn it. After that, use a tool. Our mortgage payment calculator returns the monthly principal and interest from the loan amount, rate and term, with no sign-up. If you are looking at a car loan, personal loan or any other fixed-payment debt, the loan payment calculator uses the same formula, and our guide to the loan payment formula covers the general case. More tools are on our finance calculators page.

Metriqahub

Common mistakes when calculating by hand

FAQ

How do I calculate a monthly mortgage payment?

Convert your annual rate to a monthly rate (divide by 12), multiply your years by 12 to get the number of payments, then apply M = P × [r(1 + r)^n] / [(1 + r)^n − 1]. For $300,000 at 7% over 30 years, the result is $1,995.91. Add taxes and insurance separately if they are part of your payment.

How much is a $400,000 mortgage at 7%?

Over 30 years, the principal-and-interest payment is about $2,661.21 a month. Your actual bill will be higher if your servicer also collects property taxes, homeowners insurance or mortgage insurance in escrow.

What is the monthly payment on a $300,000 mortgage at 7% for 30 years?

It is $1,995.91 for principal and interest. In the first month, $1,750.00 of that is interest and $245.91 reduces the balance.

What is an amortization schedule?

It is a table listing every payment on a loan, split into interest and principal, with the remaining balance after each one. Interest is the prior balance times the monthly rate, and principal is the payment minus interest. You can build one in a spreadsheet in a few minutes by following those two rules down the rows.

Why does my payment not match an online estimate?

The usual cause is what is included. The formula gives principal and interest only, while many estimates and servicer statements add taxes, insurance and mortgage insurance. Differences in rounding, the exact rate or the term can also move the figure by a few dollars.

Sources

Recommended

More articles

Work the numbers yourself

Our money guides go through home equity and student loan decisions in full, with calculators and every rule cited to its source.

Browse the money guides

General information, not financial advice. See our editorial standards.

Mortgage Payment Formula: How to Calculate Your Monthly Payment