You pay a small admin fee + 2 months interest + all the capital you still owe. In the early days of the loan your payments will be somewhere around a 60:40 split of capital:interest. If you borrow £30k over 3 years at 6%APR, about £1700 of your 1st year payments will be interest with £5k deposit and about £400pm payments.
At the end of year 1 then, expect about £350 in charges to settle early.