The beleaguered eurozone remains stuck in recession, according to data published Tuesday, but stock and bond markets rallied because the news raised expectations that the European Central Bank would cut interest rates as early as next week.

A closely watched survey of business managers showed that the eurozone economy was still declining and that the German economy could take longer than expected to emerge from recession.

Germany has served as the main counterweight to economic malaise elsewhere in the eurozone, and a continued slowdown there could delay a recovery on the entire Continent.

Still, markets cheered the pessimistic outlook because of expectations it will prompt the European Central Bank to take action when it meets next week. On Tuesday, the Hungarian Central Bank brought its rates down a notch, to 4.75 percent.

The French stock market index ended with a gain of 3.6 percent, while the interest rate on its 10-year sovereign bond hit a record low of 1.706 percent. Other major European stock indexes also recorded sharp gains while bond yields fell.

U.S. stocks were up about 1 percent in afternoon trading, and the 10-year Treasury bond yield touched 1.645 percent, the lowest intraday level since Dec. 12. Separately, the Dow Jones industrial average skidded more than 150 points briefly before recovering after the Twitter account of The Associated Press was hacked and a fake tweet about an attack on the White House was posted.

Outside trading rooms, though, the data was not likely to inspire joy. In Germany, for example, prolonged recession could present a problem for Chancellor Angela Merkel as her party campaigns to remain in power in elections this autumn.

The Flash Germany Composite Output index, issued by Markit, a research firm, fell to 48.8 points in April from 50.6 in March, a six-month low. A reading less than 50 is considered a sign that the economy is likely to contract.

For the eurozone as a whole, the corresponding index was unchanged at 46.5, confirming that the region remained in a rut.

In addition, economic activity in Spain declined 0.5 percent in the first three months of 2013, the Bank of Spain said Tuesday, suggesting that one of the eurozone’s most troubled economies was unlikely to start growing again until next year.

In France, the Markit output index rose to 44.2 in April from 41.9 in March, indicating that the pace of decline was slowing in the eurozone’s largest economy after Germany’s. But that tidbit of good news was clouded by a drop in the separate INSEE indicator of French business climate.

Analysts said the decline in optimism among German managers might be the result of a slowdown in the pace of growth in China, which in recent years has become one of the most important markets for German products like automobiles and machinery.

Even if Germany is merely treading water, that is still bad news for the rest of the eurozone. The German economy has played a crucial role in compensating for the swath of economic woe that runs from Cyprus to Ireland by way of Greece, Italy, Spain and Portugal.

“The German economy may not be as strong as we thought,” Marie Diron, a senior economic adviser to the consulting firm Ernst & Young, said by email.

Members of the governing council of the European Central Bank have hinted recently that an interest-rate cut could be nigh. Mario Draghi, the ECB president, said earlier this month that policymakers were “ready to act.”

The new data raised expectations that a cut in the benchmark interest rate, already at a record low of 0.75 percent, could come when the central bank meets May 2.

It is also possible that the ECB could look for other ways to ease a credit crunch in countries like Italy and Spain. Draghi has often complained that low official interest rates have not benefited companies in the troubled countries because banks remain too reluctant to lend.

“It is no longer a matter of if but when the ECB will be cutting rates,” analysts at Nomura said in a note to clients Tuesday.