North Korean state media has said that the Australian student Alek Sigley was caught committing spying acts which led to his expulsion from North Korea.

Mr Sigley, 29, disappeared around two weeks ago prompting deep concern about his fate, but was freed and flew to Japan on Thursday.

North Korea's official KCNA news agency said Mr Sigley had "honestly admitted that he had been spying by collecting our internal information and sharing with others and repeatedly asked for our forgiveness for infringing on our sovereignty".

It said that Mr Sigley - one of just a handful of Westerners living and studying in North Korea - had been detained on 25 June for promoting propaganda against the country online, including to specialist website NK News.

"Sigley, upon request by anti-DPRK news outlets such as NK News, on numerous occasions transferred information that he gathered while travelling to every corner of Pyongyang using his status as an international student, including photographs and analysis," it said, using the initials of North Korea's official name.

"The government of DPRK has exercised humanitarian forbearance and deported him from our grounds on 4 July."

Mr Sigley, who spoke fluent Korean, organised tours to North Korea.

He also ran a number of social media sites, which usually had a stream of apolitical content about life in one of the world's most secretive nations.

His blog posts focused on everyday Pyongyang - everything from the city's dining scene to North Korean app reviews - and he married his Japanese wife there last year.