How this debt versus investing model works
For debt principal L, fixed nominal APR a, and remaining term n months, monthly debt rate j = a / 12 (a as a decimal). Contract payment M = L × j / (1 − (1 + j)^(−n)); at zero APR, M = L / n. Each route has a monthly budget of M + E, where E is your extra budget. Both start with zero investments. The comparison period must cover the remaining contract term.
A pays up to M + E toward debt each month. B pays up to M toward debt. Each month, existing investments grow by i = (1 + g)^(1/12) − 1, using your effective annual return g as a decimal. Debt then accrues interest and is paid using the fixed-rate loan schedule. The actual payment is limited to the debt plus that month’s interest. The rest of each route’s M + E budget is invested at month end, including any unused amount in the final payment month. After payoff each route invests the full M + E budget. Final net financial position = investment balance − remaining debt; the difference is A minus B.
Worked illustration: debt 1,200, 0% APR, 12 months remaining, extra budget 100, investment return 0%, comparison period 12 months. M is 100 and both monthly budgets are 200. A pays 200 for 6 months, then invests 200 for 6 months. B pays 100 and invests 100 for 12 months. Both finish with no debt, no interest and 1,200 investments. If extra budget is 2,000 instead, A repays 1,200 in month 1 and invests the unused 900 in that same month; it does not wait until month 2.
Educational fixed-rate, fixed-return scenario only; not financial advice, a prediction, or a loan quote. It excludes variable rates, taxes, tax deductions, prepayment penalties, insurance, fees, investment volatility, lender applications and matching. It does not model access to invested money or liquidity needs. Investment returns are uncertain; comparing an assumed return with nominal APR alone does not establish what you should do. If both routes concern the same home, its unchanged value is omitted from both sides; this compares the debt and investment accounts only.