Beijing: China's parliament has abolished an extra-judicial system of forced labour used to punish sex workers and their clients for up to two years, but it stressed that prostitution remains illegal.

China banned prostitution after the Communist revolution in 1949, but it returned with a vengeance after landmark economic reforms began in the late 1970s, despite periodic crackdowns.

Women sit on couches in the several brothels which are disguised as hairdressing salons in the Chinese bordertown of Ruili in north-western Yunnan. Credit:Kate Geraghty

The official Xinhua news agency said China's largely rubber-stamp legislature had voted on Saturday to scrap the "custody and education" system. It said the decision would be effective from Sunday, when all those currently held in detention under the system would be released.

State media said the instruction to do away with the system had come from the cabinet and parliament had recommended a review last year, noting that the programme was increasingly not being applied in practice.