Skip to content

[codex] Add BEV loan repayment calculator - #44

Draft
yayadrian wants to merge 1 commit into
mainfrom
codex/add-bev-loan-repayment-calculator
Draft

[codex] Add BEV loan repayment calculator#44
yayadrian wants to merge 1 commit into
mainfrom
codex/add-bev-loan-repayment-calculator

Conversation

@yayadrian

Copy link
Copy Markdown
Owner

Summary

Adds a standalone UK BEV loan car repayment calculator for employees who provide a six-month employer loan car to another person.

The calculator answers how much the car user should repay each month so the employee is reimbursed for their real take-home-pay loss and company-car Benefit-in-Kind tax without treating the gross salary-sacrifice deduction as the employee's actual cost.

User impact

Repaying the gross loan rate would overcharge the car user because salary sacrifice saves the employee both Income Tax and employee National Insurance. Repaying only the net salary deduction would underpay the employee because the employee remains liable for BIK tax.

The new tool combines those two effects into six equal monthly repayments and clearly explains the supporting figures.

Implementation

  • Adds vehicle name, P11D value, gross loan rate, marginal tax rate, employee NI rate, and loan start date inputs.
  • Defaults employee NI to 8% for 20% taxpayers and 2% for 40% and 45% taxpayers.
  • Calculates Income Tax and NI salary-sacrifice savings before adding BIK tax.
  • Applies the supplied UK EV BIK rates for tax years 2025–26 through 2029–30.
  • Splits BIK rates by day when a loan crosses 6 April, totals the complete six-month cost, and produces six equal penny-rounded payments.
  • Includes an optional month-by-month rate and BIK breakdown, tax-treatment explanation, exclusions, and estimate notice.
  • Adds the calculator to the repository tools index.

Validation

  • JavaScript module syntax check passes.
  • Duplicate HTML ID check passes.
  • Cached diff whitespace check passes.
  • The supplied £76,765 / £549.99 / 40% tax / 2% NI / 4% BIK example produces £318.99 take-home cost, £102.35 BIK, £421.35 per payment, and £2,528.10 across six equal payments.
  • A loan spanning 6 April was checked to ensure both tax-year rates appear in the calculation and all six breakdown rows are produced.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant