HONG KONG — Kimbo Chan knows all about the food scandals in China: the formaldehyde that is sometimes sprayed on Chinese cabbages, the melamine in the milk and the imitation soy sauce made from hair clippings. That is why he is growing vegetables on a rooftop high above the crowded streets of Hong Kong.

“Some mainland Chinese farms even buy industrial chemicals to use on their crops,” Mr. Chan said. “Chemicals not meant for agricultural uses at all.”

As millions of Hong Kong consumers grow increasingly worried about the purity and safety of the fruits, vegetables, meats and processed foods coming in from mainland China, more of them are striking out on their own by tending tiny plots on rooftops, on balconies and in far-flung, untouched corners of highly urbanized Hong Kong.

“Consumers are asking, will the food poison them?” said Jonathan Wong, a professor of biology and the director of the Hong Kong Organic Resource Center. “They worry about the quality of the food. There is a lack of confidence in the food supply in China.”