A visa expired by one day can mean fines, detention, even entry restrictions.
Visa types. L-visa (tourism), M-visa (business), Q-visa (family visit), Z-visa (work), X-visa (study).
Residence permit. Planning a long stay in China (over 180 days), you need a foreigner's residence document. After entering on a Z or X visa, apply within 30 days.
Visa extension. Be sure to handle before expiry. Applying after overstaying brings penalties.
Permanent residence. Continuously resident in China for five years, at least nine months a year, you can apply for the Foreign Permanent Resident ID Card ("China green card").
Passport renewal and visa transfer. After renewing an expired passport, you need to apply for visa transfer annotation onto the new passport, or carry both old and new passports together.