See the monthly payment and a year-by-year amortization schedule for any loan.
An amortization schedule shows how each payment on a loan is split between interest and principal over time. In the early years almost all of your payment goes to interest, because the balance is at its largest. As the balance shrinks, more of each payment goes to principal, and the loan pays off faster near the end.
The schedule is built month by month: interest for the month equals the remaining balance times the monthly rate, and the rest of the payment reduces the balance. Extra payments go straight to principal, which cuts the interest on every following month and shortens the loan.