Japan's exports rose more than forecast in July, bouncing back from two straight declines to support an economy that contracted last quarter by the most since the period immediately following the Great East Japan Earthquake in March 2011.

Overseas shipments rose 3.9 percent from a year earlier, the Finance Ministry said in Tokyo on Wednesday. That's higher than the median estimate for a 3.8 percent gain in a Bloomberg News survey of 28 economists. Imports, meanwhile, rose 2.3 percent, leaving a deficit of ¥964 billion.

The rebound in shipments may aid Prime Minister Shinzo Abe in his push to raise the sales tax for a second time following a boost to 8 percent in April. The economy is forecast to expand by an annualized 2.9 percent this quarter after contracting 6.8 percent in the April-June period, when consumers and businesses cut spending after the tax increase.