Japan posted a trade surplus of 255.3 billion yen ($2.34 billion) in April compared with a deficit of 936.9 billion yen in the same month a year earlier and beating a market consensus of a surplus of 140 billion yen, according to data from the Finance Ministry Thursday.

Exports jumped 38% year over year to 7.18 trillion yen while imports rose 12.8% to a 27-month high of 6.93 trillion yen, the ministry said. For the first four months of the year the trade surplus was at 809.54 billion yen compared with a gap of 1.14 trillion yen a year ago.

The rise in exports was the steepest growth in outbound shipments since April 2010 and was driven by "signs that a recovery in global trade gained strength." By sector transport equipment sales rose 69.4% thanks to motor vehicles - up 88.9% - and machinery, which was up 40.3%.

Exports rose to most countries.

"While export values rose further in April, the rebound in exports is slowing and external demand is unlikely to provide much of a tail wind to growth over the coming months. The 38.0% annual rise in export values in April was stronger than the Bloomberg median of a 31.9% rise," Capital Economics said Thursday. "The chunky annual figure was down to base effects from the severe weakness in exports in April 2020."

Meanwhile, import values rose 12.8% on year in April after a 5.8% rise in March. In month-on-month terms import values rose by 7.5%. "The merchandise trade data suggest that net trade could boost gross domestic product growth by around 0.1% percentage points this quarter. That's broadly in line with our forecast and consistent with our view that quarterly gross domestic product growth was zero this quarter," Capital Economics' Japan economist Tom Learmouth said.

"The trade data confirmed that exports were recovering steadily. Particularly car exports, which fell a lot last year, are picking up," Meiji Yasuda Research Institute chief economist Yuichi Kodama said in a Reuters report.

"In Japan, capital spending tends to move in sync with external demand, so an export recovery is encouraging for machinery orders and capital expenditure."

Meanwhile, separate data from the Cabinet Office showed Japan's core machinery orders, considered by economists to be an indicator of capital spending in the coming six to nine months, rose 3.7% in March from the previous month.

Japan's economy fell back into decline in the first quarter and economists have revised down estimates for growth this quarter as emergency virus restrictions harm consumer spending that makes up more than half the economy.