In a statement posted on the Twitter-like Weibo, Shenzhen police said Cheng was 'punished with administrative detention for 15 days for violating the law of the People's Republic of China on public safety management'
A British consulate employee detained in China has returned to Hong Kong, his family said Saturday, ending a two-week ordeal during which Beijing's state media smeared him with lurid allegations.
Simon Cheng disappeared after visiting the neighbouring city of Shenzhen on August 8 and was placed in administrative detention by police, unable to contact his family or his British employers.
He was returning to Hong Kong on a high-speed train and sent messages to his girlfriend as he was about to go through customs, shortly before he was stopped by Chinese authorities.
In a statement posted on the Twitter-like Weibo, Shenzhen police said Cheng was "punished with administrative detention for 15 days for violating the law of the People's Republic of China on public safety management."
On Saturday Cheng's relieved family announced his return.
"Simon has returned to Hong Kong," his family said in a Facebook post, adding he would take "some time to rest and recover."
Britain's Foreign Office said "we welcome the release of Simon Cheng and are delighted that he can be reunited with his family."
"Simon and his family have requested privacy and we would be grateful if this is respected," the department said in a statement.
Cheng was released Saturday as the term had expired, the police said, adding he had "confessed to the facts of his illegal activity", but without saying what he was accused of.
The incident came as relations between Britain and China have become strained over what Beijing calls London's "interference" in pro-democracy protests that have wracked Hong Kong for three months.
During Cheng's detention, Chinese-state media published unproven allegations about him and the possible reason for his detainment.
The Global Times, a state-run tabloid newspaper, said he had been held for "soliciting prostitutes", citing police in Shenzhen.
In an editorial on Friday, the tabloid said it was at Cheng's request that police did not contact his family and that "thanks to the British foreign ministry and media, which have been hyping it, the case is now fully exposed."
But a Facebook page run by Cheng's family dismissed the report of solicitation.
"This is a made-up crime of soliciting prostitution, everyone should see it's a joke," the post said.
China promised to respect the freedoms in the semi-autonomous territory of Hong Kong after its handover from Britain in 1997 - including freedom of speech, unfettered access to the internet and an independent judiciary.
But the protesters who have tipped the city into an unprecedented political crisis say these rights are being chipped away.
The spark for the demonstrations - now entering their third month - was an attempt to pass a bill allowing extradition to China.
The bill has been suspended but not formally withdrawn, raising fears it could be revived by Hong Kong's Beijing-buttressed government.
Since the demonstrations, Chinese authorities have increased their inspections at the border -- including checking the phones and devices of some passengers for photos of the protests.
Beijing has faced criticism previously for detaining foreign nationals during diplomatic spats, and for accusing dissidents or activists of sex crimes.
Saturday saw more protests in the city, with black-clad demonstrators marching across a working-class area of HongKong.