Stocks rallied in Asia and Europe after OPEC’s surprise announcement of a deal to cut crude output spurred a surge in oil late Wednesday. India’s assets fell after it attacked terrorist targets in Pakistan.

Energy companies led gains on the MSCI All-Country World Index, which is on course for its best quarter since 2013. The ringgit was the best performer among Asian currencies as prospects brightened for Malaysia, Asia’s only major net oil exporter, and the yen slid by the most this month. Sovereign bonds fell amid speculation higher energy prices will revive inflation. After posting its biggest gain in five months, crude slipped under $47 a barrel. India’s rupee fell the most in three months after the biggest military escalation since 1999.

A global oil glut has weighed on crude prices for more than two years, damping inflation, hurting corporate earnings, and leading to negative bond yields in two of the world’s four biggest economies. The Organization of Petroleum Exporting Countries said its members agreed a preliminary deal to trim production to a range of 32.5 million to 33 million barrels per day following informal talks in Algiers, although it won’t decide on targets for each country until a November meeting in Vienna.

“It really caught people on the hop — we weren’t expecting a cut in output at all,” said Derek Mitchell, a fund manager at Royal London Asset Management in London. His fund owns shares of Royal Dutch Shell Plc and BP Plc and has assets under management of 93.8 billion pounds ($122 billion). “It sends a message that there’s now a floor under the oil price. A tighter oil market will support earnings. There’s rightly a great deal of skepticism as to whether this cut will last, but for the time being, it’s a very nice thing to wake up to.”

Read more Bloomberg

A large display of daily stock market price and quotations during normal economic period with decorative crystal ball flags of main country in the world