Okay, let's math it out.
Pay off car loan.
$15,000 car loan. 6% interest. Assuming 5 year payoff. Solve for payment=$289.99.
60 payments at $289.99 = $17,399.62. Total interest = $2,399.62.
Interest saved by paying off the car loan= $2,399.62.
Pay down mortgage.
$200,000 mortgage at 4% for 30 years. Solve for payment=$954.83.
360 payments at $954.83 = $343,738.80.
If you put the $15,000 towards the mortgage:
$185,000 mortgage, 4%, 954.83 payment, payoff in 311.92 months. 311.92 X 954.83 = $297,830.58.
Interest saved over the entire loan by paying an extra $15,000 at the beginning= $30,908.22.
Based on that math it would appear MilesTeg is correct. However, what this math ignores is that if you pay the car off early you have an extra $289.99 per month you could put towards the mortgage. That extra $289.99 per month should have a greater impact on the mortgage than the $15,000 single payment.
Let's test it out over the 30 years.
Pay $15,000 towards mortgage.
Car loan: $15,000 car loan. 6% interest. Assuming 5 year payoff. Solve for payment=$289.99.
60 payments at $289.99 = $17,399.62.
Mortgage years 1-5: $185,000, 4%, $954.83 payment, 60 payments. Remaining balance after 5 years: $162,580.12.
Mortgage years 6-payoff: PV=162,580, 1244.82 payment. Payoff in 171.75 payments. 1244.82 X 171.75 + 954.84 X 60 = 271,088.24.
Total payments: 271,088.24 + 15,000 + 17399.62 = $303,487.86
Pay off the car loan, and then direct extra funds towards mortgage debt.
Car loan: $0
Mortgage: $200,000, 4%, $1,244.82 payment. Payoff in 230.45 payments. 1244.82 X 230.45 = $286,868.769.
Total payments: 286,868.77 + 15,000 = $301,868.77.
Conclusion: Paying off the highest interest rate debt first is the fastest way to pay down debt, even if the higher interest debt is a smaller dollar amount.
EDIT: at the request of readers I ran my scenarios over the full 30 years instead of the first 5.