Yes in short. Pension contributions reduce your taxable income, so if you contribute to bring you back under the threshold then the tapering personal allowance can be reclaimed.
Makes it a no brainer really if you can afford the contributions, as in real terms you'll save 60% income tax (+NI) on that £25k.