It will receive an initial tranche of £1.5bn to fund it until September 2025.
The loan gives the UK’s biggest water provider time to sort out its finances and could ward off nationalisation.
Court approval had been needed for the rescue plan centred on an emergency £3bn loan.
The business is provisionally attempting to borrow its way out of its financial problems as it struggled with £16bn in debt.
It had said it would run out of money by 24 March.
The government has been on standby to put Thames Water into special administration, a form of temporary nationalisation aimed at keeping the taps on in the event of financial collapse.
This breaking news story is being updated and more details will be published shortly.
Please refresh the page for the fullest version.
You can receive breaking news alerts on a smartphone or tablet via the Sky News app. You can also follow us on WhatsApp and subscribe to our YouTube channel to keep up with the latest news.