According to Chinas most recent National Census of 2010, the first to record the number of foreign residents, there were at least 600,000 expats living in the country. However, now it is estimated around 1 million.
Geographic Distribution of China Expat Population (As per the source)
Most foreigners live in Guangdong, the richest Chinese province and the first one to lead Chinese economic development after the country started to open up in the late 70s.
Shanghai has the next largest expat population in China that stood at over 209,000 few years ago. It has most likely doubled since then. Beijing is the third largest population center for expats.