(CNN) -- The Chinese government has lifted a 20-year-old rule that banned foreigners with HIV and AIDS, sexually transmitted diseases and leprosy from entering the country, according to the country's state news agency.
State-run news agency Xinhua reported Tuesday that China's State Council decided to repeal the ban after realizing it did little to prevent the spread of disease and caused problems when the country was hosting international events.
The revision came days before the opening of the six-month Shanghai World Expo, which organizers expect will draw 70 million people. The government had previously lifted the ban temporarily for other large-scale events, including the 2008 Olympics in Beijing.
Xinhua said the health ministry estimates the number of people living with HIV in China had reached 740,000 by October 2009, with deaths caused by AIDS totaling 49,845 since the first case was reported in 1985.
China's decision comes several months after the U.S. Department of Health and Human Services and the Centers for Disease Control and Prevention removed HIV infection from the list of diseases that prevent non-U.S. citizens from entering the country.
Until January, the U.S. was one of seven countries with laws barring entry of people with HIV, according to amfAR, an AIDS research organization.