How Mortgage Payments Are Calculated

A mortgage payment has two parts. Principal and interest are set by the loan amount, the monthly rate and the number of payments, using the amortization formula. Property tax, insurance, mortgage insurance and HOA dues are added on top and never touch the balance. The sections below show which of those lines moves the payment most.

What a mortgage payment is made of

A mortgage payment is two bills stapled together. The first is principal and interest, the money that actually retires the loan. The second is the escrow-style collection: property tax, homeowners insurance and, where one applies, mortgage insurance or a homeowners association fee. Only the first part is loan math. The rest are pass-through costs, and they move whenever a county reassessment or a new insurance premium moves.

The loan amount is the home price minus the down payment, not the price itself. On a $400,000 purchase with 20% down the loan is $320,000, and at 6.5% over 30 years that is $2,022.62 a month in principal and interest. Borrow $400,000 at the same rate and term and the payment is $2,528.27. Both figures come from the mortgage payment calculator with tax, insurance and HOA set to zero, so no escrow line is blurring the comparison.

That split matters when a payment feels too high. Doubling the tax line and the interest line have nothing to do with each other: the first is a bill your servicer forwards, the second is the price of the money.

The amortization formula, step by step

Principal and interest come from the annuity formula that lenders use to set a fully amortizing payment. Write P for the loan amount, r for the annual rate divided by 100 and then by 12, and n for the term in years multiplied by 12.

P = home price - down payment r = annual rate / 100 / 12 n = term in years * 12 payment = P * r * (1 + r)^n / ((1 + r)^n - 1) when r > 0 payment = P / n when r = 0

Two details do most of the work. The rate is divided by 12 both in the numerator and inside the exponent, so a 6.5% note becomes r = 0.0054166..., not 6.5. And the formula assumes the rate never changes and that no extra principal is ever paid; one extra payment breaks the clean equality. That is why the amortization schedule calculator rebuilds the balance month by month rather than trusting the closed form.

Interest in any single month is simply the remaining balance times r. On the $400,000 loan above, month one interest is $400,000 × 0.0054166..., or $2,166.67, and principal is whatever is left of the $2,528.27 payment: about $362.

Change one input at a time

The fastest way to see which input matters is to move one and hold the other two still. Every row below is output from this site's calculator for a $400,000 loan at 6.5% over 30 years, except for the single value named in the row.

Monthly principal and interest and total interest, per this site's mortgage payment calculator, for a $400,000 loan at 6.5% over 30 years unless the row changes that input
What changes Loan amount Rate Term Monthly P&I Total interest
Baseline $400,000 6.5% 30 years $2,528.27 $510,177.95
P: smaller loan (20% down) $320,000 6.5% 30 years $2,022.62 $408,142.36
r: one point lower $400,000 5.5% 30 years $2,271.16 $417,616.16
r: one point higher $400,000 7.5% 30 years $2,796.86 $606,868.89
n: 15-year term $400,000 6.5% 15 years $3,484.43 $227,197.30

The pattern is worth memorizing. Cutting the loan by 20% cuts the payment by exactly 20%, because the formula is linear in P. A one-point rate change moves the payment about 10%, and it moves total interest far more: 7.5% costs $606,868.89 in interest against $510,177.95 at 6.5%. The gap between the 5.5% and 7.5% rows is $189,252.73 of interest on an otherwise identical loan, which no choice of term recovers. The term is the lever with the biggest visible effect on the monthly bill and the smallest effect on affordability, which is why the down payment calculator is the better first stop when you are choosing a price range rather than a lender.

Why the early years are interest-heavy

Because interest is charged on the balance, and the balance starts at its highest, the first payments are mostly interest. On the $400,000 loan at 6.5%, the first payment of $2,528.27 contains $2,166.67 of interest and $361.60 of principal: 85.7% of the money you send does not reduce the debt.

Twelve payments later, $30,339.24 has left your account and the balance is $395,529.10, so only $4,470.90 went to principal. By month 120 the balance is $339,104.51, and by month 240 it is $222,661.13. The crossover, where principal finally exceeds interest inside one payment, arrives far later than most people expect.

A shorter term does not change month-one interest at all: it is still $2,166.67 on the same balance and rate. What changes is the payment around it. At 15 years the same interest is 62.2% of a $3,484.43 payment, so more of every month attacks the balance, which is why total interest falls to $227,197.30. If extra principal is the plan, the loan payoff time calculator shows what a fixed extra amount per month does to the payoff month.

Escrow items that sit outside the formula

Property tax, homeowners insurance and HOA dues are collected with the mortgage but are not loan costs. They earn no interest and retire no principal, and they stop when you sell even though the loan is unaffected. The calculator's default inputs (1.2% a year and $1,800 a year) put a $400,000 home at $4,800 of tax, or $400 a month, and $150 a month of insurance. Those two lines add $550 to the bill and change the answer to "can I afford this" far more often than a quarter point of rate does.

Mortgage insurance is a fourth line with its own rules. Conventional lenders usually require it when the loan is more than 80% of the home value, which is the threshold the CFPB describes as the point where PMI stops being required (CFPB, retrieved 2026, consumerfinance.gov). On a $400,000 purchase with 10% down, the loan is $360,000 and the site's default rate of 0.55% a year works out to $165 a month. That premium is an input you can change, not a market quote: insurers price it on credit history, loan-to-value and coverage.

If the question is owning versus renting rather than loan versus loan, the rent vs buy calculator puts tax, insurance, maintenance and appreciation in one place, which is where escrow costs belong.

What the payment number leaves out

A payment is an estimate of a monthly bill, not a loan offer. Four things are deliberately outside it. Closing costs, points and lender fees are paid at settlement and never appear in the payment. Prepayment penalties and extra payments are not modeled, so a borrower who rounds up every month will finish earlier than the schedule shows. Property tax and insurance are held flat for the whole term, while real bills tend to rise with assessments and rebuild costs. And the rate is treated as fixed, which is accurate for a fixed-rate loan and wrong for an adjustable one after its first reset.

The last point is the one that bites. Modeling an adjustable-rate mortgage as if its starter rate lasted 30 years understates later payments if the index rises and overstates them if it falls. The refinance break-even calculator is the right tool for the comparison that a payment alone cannot answer: closing costs divided by the monthly saving gives the number of months before a new rate has paid for itself.

The formula, the default assumptions and the rounding rules are written out on the methodology page so any figure here can be reproduced.

Frequently asked questions

Is the monthly payment the same as principal and interest?

No. Principal and interest is the loan part, and it is the only part the amortization formula produces. A monthly housing payment usually also includes property tax, homeowners insurance and sometimes mortgage insurance or an HOA fee, which lenders collect through escrow. Those extra lines are estimates of bills your servicer forwards, not loan costs, and they can change in any year even when the rate and balance do not.

Why does the calculator ask for a home price and a down payment instead of a loan amount?

Because the loan is the difference between the two, and the home price is also the base for property tax and for the loan-to-value ratio that decides whether mortgage insurance applies. Entering a price and a down payment keeps those three numbers consistent. If you already know the loan amount, set the down payment to zero and enter the loan as the price; tax and insurance inputs can then be set to zero as well.

Does a longer term always lower the monthly payment?

Yes for principal and interest, and the effect is large: on a $400,000 loan at 6.5%, a 30-year term is $2,528.27 a month against $3,484.43 at 15 years. Total interest moves the other way, from $227,197.30 to $510,177.95 in that comparison. A longer term also keeps the balance higher for longer, which matters if mortgage insurance or a future refinance is part of the plan. Escrow lines do not change with the term.

Why is total interest more than the amount borrowed?

Because interest is charged every month on whatever balance remains, and the balance declines slowly at first. On a $400,000 loan at 6.5% for 30 years, the payments total $910,177.95, of which $510,177.95 is interest. Most of that interest is charged in the first half of the schedule. A shorter term or a lower rate attacks the total directly; extra principal does too, which is why the closed-form total only matches a loan with no extra payments.

Can I use this formula for an adjustable-rate mortgage?

Only up to the first reset. The formula assumes one rate for the whole term, so for an adjustable loan it describes the initial period accurately and everything after it poorly. A realistic check is to price the same balance at the highest rate the caps allow for the remaining term. This site holds the rate fixed in every calculator, so an adjustable loan should be modeled as a fixed loan plus a separate stress test on the reset rate.

Related calculators

Estimates only, not financial advice. Thresholds, cancellation rights and rate caps depend on your loan documents and your servicer. See Disclaimer.

By Panyian, editor and maintainer · Updated · How this site is maintained