NUSA DUA, Indonesia (Reuters) - Japanese Prime Minister Shinzo Abe and Chinese President Xi Jinping shook hands during an APEC regional summit in Bali on Monday but had no talks on a territorial island dispute, Japanese officials said.

Relations between the world's second- and third-largest economies have been troubled for months because of a sovereignty dispute over tiny islands in the East China Sea known as the Senkaku in Japan and the Diaoyu in China. The two also remain at odds over their respective conduct during World War Two.

Abe and Xi also shook hands on the fringes of the G20 summit in St. Petersburg in September, the first such show of cordiality between the two since they took office.

Tomohiko Taniguchi, a councilor for the cabinet secretariat in Abe's office, said the premier was open to talks with Beijing that would sidestep the thorny islands dispute, which has been exacerbated by the purchase of several of the islands late last year by the Japanese government from a private owner.

"There is just one area of issue that it is pretty hard for the Japanese to discuss and that is the islands issue," he said. "If we agree to discuss this issue, it would be tantamount to agreeing on the existence of a sovereignty issue."

Tokyo's purchase of three of the uninhabited islands spurred major Chinese protests and a boycott of Japanese goods in China.

The United States, which has a hefty military presence in Japan including on the southern island of Okinawa, close to the disputed isles, has expressed concern about the dispute and has been keen to see a diplomatic solution.

(This story is corrected with second reference to Chinese president's name to Xi from Jinping in paragraph 3)

(Reporting by Randy Fabi; Writing by James Pomfret; Editing by Mark Heinrich and Paul Tait)