LONDON – The British government’s plan to raise a tax on luxury-home purchases sparked a last-minute dash by real-estate brokers to wrap up deals before the deadline hit in March. They needn’t have bothered.

Sales of homes valued at $3.2 million more than doubled in May from a year earlier, according to the most recent data available from the Land Registry. After a 40 percent decline in April, sales rebounded as overseas investors took advantage of Britain’s status as a haven from economic and political turmoil.

“Money is leaving the euro zone and being spent on a safe asset,” Matthew Pointon, an economist at researcher Capital Economics, said. “Safe-haven flows outweigh the increase in the stamp duty.”

Luxury homes have held their value better than cheaper residential properties in Britain because of a scarcity of prime real estate for sale, particularly in London. That has led to record prices paid for homes in the city’s Mayfair, Kensington and Knightsbridge districts.

Chancellor of the Exchequer George Osborne’s annual budget targeted luxury-home purchases to help narrow Britain’s record deficit. He raised a transaction tax known as stamp duty on homes sold for more than 2 million pounds to 7 percent from 5 percent. The use of corporations set up in offshore tax havens such as the Cayman Islands to avoid the tax spawned a 15 percent levy on purchases of homes by companies.

In May, 113 houses and apartments sold for more than 2 million pounds, up from 45 a year earlier, according to the Land Registry. In London, sales jumped to 97 from 40, led by investors from mainland Europe and the Middle East.

Homes valued at 10 million pounds or more gained 2.9 percent in price.