New Delhi: In a major breakthrough, UK clinched a Brexit trade deal with the European Union on Thursday, just seven days before it exits one of the world’s biggest trading blocs in its most significant global shift since the loss of empire.

“Deal is done,” the Downing Street said in a statement, adding, “We have taken back control of our money, borders, laws, trade and our fishing waters.”

“The deal is fantastic news for families and businesses in every part of the UK. We have signed the first free trade agreement based on zero tariffs and zero quotas that has ever been achieved with the EU.”

The breakthrough came Thursday with just over a week to go until the UK’s split is completed. Now comes the race to approve and ratify the deal before the U.K. leaves the EU’s economic structures at the end of the year. The British and European parliaments both must hold votes on the agreement.

Months of tense and often testy negotiations gradually whittled differences between the two sides down to three key issues: fair-competition rules, mechanisms for resolving future disputes and fishing rights. The rights of EU boats to trawl in British waters remained the last obstacle before it was resolved.

British Prime Minister Boris Johnson had insisted the UK would “prosper mightily” even if no deal were reached and the UK had to trade with the EU on World Trade Organization terms. But his government has acknowledged that a chaotic exit was likely to bring gridlock at Britain’s ports, temporary shortages of some goods and price increases for staple foods.

Britain withdrew from the EU’s political institutions on January 31, and an economic transition period expires on December 31.

(With input from agencies)