Global stock markets shot higher on Wednesday after a US company reported positive test results for a drug used in treating the new coronavirus, more than offsetting news of a massive downturn in the American economy.

Meanwhile data showing crude stockpiles in the United States rising less than expected sent oil prices spiking, with US benchmark oil WTI soaring by more than a third before dialing the gains back.

US and European stocks both advanced after Gilead Sciences said that remdesivir, one of the most highly anticipated drugs being tested for use against coronavirus, showed positive results in a large-scale US government trial.

"The data shows that remdesivir has a clear-cut, significant, positive effect in diminishing the time to recovery," said top US government epidemiologist Anthony Fauci.

And the US Federal Reserve did no harm when it kept interest rates unchanged at zero and said that, though a big economic downturn was almost certain to happen in the second quarter, it would be there to help.

The central bank is "committed to using our full range of tools to support the economy... to assure that the recovery when it comes will be as robust as possible," Fed Chair Jerome Powell told reporters.

The Fed's muscular response and bounce-backs of China and other economies hit by COVID-19 outbreaks have traders feeling optimistic, said Art Hogan, chief market strategist at National Securities.

"Investors are sensing that there's an end to it," he said. "The market is looking ahead to the fourth quarter and thinking it's going to be better than the second quarter."

Among the day's winners were Google parent Alphabet, which surged 8.7 percent as the company's results outshone dim earnings expectations.

That lent momentum to Apple, Amazon and other tech giants that won big gains Wednesday and are set to report their own results in coming days.

Boeing jumped 5.9 percent despite reporting a $641 million loss as the company announced a plan to cut its workforce by 10 percent and expressed confidence it had sufficient liquidity to weather the deep downturn in business.

Enthusiasm over remdesivir powered shares of Gilead to a 5.7 percent increase at the close.

The drug is an anti-viral medicine and not a vaccine -- meaning it could help treat those infected with the coronavirus but not block new infections -- which is key to ending lockdowns and other restrictions that have hammered the global economy.

"Investors should know the script by now," said Chris Beauchamp, chief market analyst at online trading firm IG.

"This is a market that ignores or rides out bad news and focuses on the good data, no matter how limited that might be," he said.

The bad news Wednesday was a worse than expected 4.8 percent contraction in US first quarter GDP.

It was the biggest decline since the Great Recession and ended more than a decade of growth for the world's largest economy.

"The market's sanguine reaction to the US GDP figure may seem odd, but investors were aware that Q1 would be bad, and indeed are also aware that Q2 will be worse," Beauchamp said.

While some countries are moving to ease lockdowns as the virus shows signs of easing, there are worries that reopening to early could lead to a second wave of infections
While some countries are moving to ease lockdowns as the virus shows signs of easing, there are worries that reopening to early could lead to a second wave of infections AFP / ULISES RUIZ

Investors will next hear from the European Central Bank, which holds its monetary policy committee meeting on Thursday.

New York - Dow: UP 2.2 percent at 24,633.86 (close

New York - S&P 500: UP 2.7 percent at 2,939.51 (close)

New York - Nasdaq: UP 3.6 percent to 8,914.71 (close)

London - FTSE 100: UP 2.6 percent at 6,115.25 points (close)

Frankfurt - DAX 30: UP 2.9 percent at 11,107.74 (close)

Paris - CAC 40: UP 2.2 percent at 4,671.11 (close)

Milan - FTSE MIB: UP 2.2 percent at 18,067.29 (close)

Madrid - IBEX 35: UP 3.2 percent at 7,0555.70 (close)

EURO STOXX 50: UP 2.2 percent at 2,996.08 (close)

Hong Kong - Hang Seng: UP 0.3 percent at 24,643.59 (close)

Shanghai - Composite: UP 0.4 percent at 2,822.44 (close)

Tokyo - Nikkei 225: Closed for a holiday

Brent North Sea crude: UP 10.9 percent at $22.69 per barrel

West Texas Intermediate: UP 25.12 percent at $15.44 per barrel

Euro/dollar: UP at $1.0874 from $1.0820 at 2100 GMT

Dollar/yen: DOWN at 106.66 yen from 106.87

Pound/dollar: UP at $1.2467 from $1.2426