* Topix turnover lowest since Dec. 2014
* Oil shares outperform on tensions in Middle East
* Investors unwind both long and short positions - analyst
By Ayai Tomisawa
TOKYO, June 24 (Reuters) - Japan's Nikkei edged higher in cautious trade on Monday as investors looked ahead to this week's G20 summit amid a backdrop of rising trade and geopolitical tensions.
The Nikkei share average ended 0.1% higher at 21,285.99 points, after traversing positive and negative territory.
The broader Topix gained 0.1% to 1,547.74, with only 830 million shares changing hands, the lowest level since December 2011. Turnover was 1.4 trillion yen, the lowest since December 2014.
Analysts said investors were on the sidelines ahead of an expected meeting between Chinese and U.S. leaders on the sidelines of the G20 summit on June 28-29 in Osaka, Japan.
China's President Xi Jinping will attend the G20 summit, state-run Xinhua news agency said on Sunday, giving the first official confirmation of his attendance at a gathering where he is expected to meet U.S. President Donald Trump. Markets are hoping the two leaders could help restart stalled talks to resolve a months-long trade war.
"It's good that Trump and Xi are meeting but we still don't know what comes out of the meeting so investors are unwinding both their long and short positions," said Yutaka Miura, a senior technical analyst at Mizuho Securities.
Tensions in the Middle East also kept investors on edge.
Trump said on Sunday he was not seeking war with Tehran after a senior Iranian military commander warned any conflict in the Gulf region could spread uncontrollably and threaten the lives of U.S. troops.
But U.S. Secretary of State Mike Pompeo also said "significant" sanctions on Iran would be announced on Monday aimed at further choking off resources that Tehran uses to fund its activities in the region.
That kept oil prices high, and pushed up Cosmo Energy Holdings 1.5% and Idemitsu Kosan 0.8%.
Exporters - especially those with large exposure to China - were down as the dollar remained pressured against the yen, with signs the Federal Reserve might move to cut rates soon denting the greenback.
Tokyo Electron shed 1.7% and TDK Corp dropped 0.8%. (Editing by Shri Navaratnam & Kim Coghill)