How it works
The calculator first derives the instalment from the original terms, then computes what the balance must be after the instalments you have paid. It uses a closed form — the principal grown forward at the monthly rate, less the instalments grown forward — which gives the same answer as walking the schedule month by month, and the two are checked against each other.
It then splits everything you have paid into two parts. Whatever reduced the principal is the principal cleared; the rest was interest. That split is the useful part, because the two are wildly unequal early in a loan.
More detail
The percentages are the point worth studying. On a 20-year loan, paying a quarter of the instalments clears nowhere near a quarter of the principal — interest is charged on the outstanding amount, so it takes the largest share of the earliest payments.
Any prepayment you have already made is not modelled, so a real balance will be lower than the figure here if you have paid extra at any stage.
Because so much interest is still ahead of you early in a loan, the prepayment calculator.
For the full month-by-month schedule behind these figures, use the EMI calculator.