It is not illegal. If it is used for trademarks and advertisements, intentional damage is illegal.
According to the "Flag Law of the People's Republic of China"
Article 3 The national flag of the People's Republic of China is the symbol and symbol of the People's Republic of China. Every citizen and organization should respect and care for the national flag.
Article 17 A damaged, defaced, faded or substandard national flag shall not be flown.
Article 18 The national flag and its patterns shall not be used as trademarks or advertisements, nor may they be used for private funeral activities.
Article 19: Anyone who intentionally insults the national flag of the People’s Republic of China and the People’s Republic of China by burning, damaging, scribbling, defiling, or trampling on it in a public place shall be investigated for criminal responsibility in accordance with the law; the circumstances are relatively minor. , shall be detained by the public security organs for a period of not more than fifteen days.
Extended information
Crime case: Four defendants in Guizhou were sentenced for insulting the national flag
A case of insulting the national flag was prosecuted by the People's Procuratorate of Longli County, Guizhou Province. Recently, the Longli County People's Court held a public hearing and pronounced a verdict. Four defendants were sentenced to fixed-term imprisonment ranging from 8 to 9 months.
The reporter learned from the procuratorate that on February 6, 2018, villagers in Yudong Village, Wantanhe Town, Longli County went to the Yudong Village Committee to cause trouble because their demands were not met.
The four defendants, Yang Moumou, Wu Moumou A, Wu Moumou B, and Tang Moumou, climbed up to the second floor of the Yudong Village Committee Office. Tang Moumou pulled the national flagpole towards him, and Yang Moumou XX, Wu XX, and Wu XX together tore the national flag from the flagpole, tore it into pieces, and threw it into the village committee courtyard. On February 24, Tang Moumou voluntarily surrendered to the public security organ and truthfully confessed the crime.
After trial, the court held that the four defendants deliberately insulted the national flag of the People's Republic of China by damaging it in public. Their actions had violated the law and constituted the crime of insulting the national flag. They were sentenced in the first instance. Yang Moumou, Wu Moumou A, and Wu Moumou B were sentenced to 9 months in prison, and Tang Moumou was sentenced to 8 months in prison.
Baidu Encyclopedia - "Flag Law of the People's Republic of China"
China Court Network - Four defendants in Guizhou were sentenced for insulting the national flag