As she drove down a busy four-lane road near her old home, Tang Huiqing pointed to the property where her dead sister’s workshop once stood. The lot was desolate, but for Ms. Tang it lives.

Four years ago, government officials told her sister that Chengdu was expanding into the countryside and that her village had to make way. A farmer who had made the transition to manufacturer, she had built the small workspace with her husband. Now, officials said, it would be torn down.

“So my sister went up to the roof and said, ‘If you want to, tear it down,’ ” Ms. Tang said.

Her voice trailed off as she recalled how her sister poured diesel fuel on herself and after pleading with the demolition crew to leave, set herself alight. She died 16 days later.

Over the past five years, at least 39 farmers have resorted to this drastic form of protest. The figures, pieced together from Chinese news reports and human rights organizations, are a stark reminder of how China’s new wave of urbanization is at times a violent struggle between a powerful state and stubborn farmers — a top-down project that is different from the largely voluntary migration of farmers to cities during the 1980s, ’90s and 2000s.