the pine needle gall midge, Thecodiplosis japonensis Uchida et inouye, is a newly invasive pest in china that mainly harms Pinus thunbergii and P. densiflora. the occurrence and damage caused by T. japonensis in pure stands of P. thunbergii were investigated, and the needle growth and needle compound content were measured. Based on the above steps, the growth dynamics of galls and chemical defense response of P. thunbergii to attack by the gall midge were revealed. the results showed that the adults of T. japonensis in Qingdao city, china, emerged from the end of May to late July, with a peak in mid-June. needles of P. thunbergii began to differentiate in late June and stopped growing in mid-September. The length of infested needles was 60.17% less than that of healthy needles. On average, there were 9 ± 4 larvae in each gall, 22 at most and 1 at least. The number of larvae within a gall had no significant effect on the size of the gall or larvae. Compared with that in the ungalled tissues, the content of amino acids in the galled pine needle tissues increased by 40.83%, while the content of total polyphenols, tannins, carotenoids, total triterpenes, total alkaloids and other secondary substances decreased to varying degrees, which was favourable for the growth and development of the T. japonensis larvae. There are approximately one million named insects and more than 500,000 plants on Earth, accounting for more than half of the total global biodiversity 77. During the long-term process of natural selection, plants and insects are closely related in regard to nutrition, reproduction, protection, defence and diffusion. Plants provide food and habitat for insects, but insects also provide many benefits to plants, such as seed dispersal and pollination 37. There are many ways by which insects obtain nutrition from plants. Some insects, such as beetles, moths, and wasps, directly eat the leaves, stems and roots of plants, which affects the absorption of nutrients and the performance of photosynthesis by plants 26,54,74. Some suck the sap from plant tissue, such as aphids, red spiders, and whiteflies 13,19,28 , which causes the loss of green colouration, the deformity of plant tissue and plant death. In general, host plants respond positively to damage caused by pests. For instance, almost all secondary metabolites, including nitrogenous compounds (such as alkaloids and non-protein amino acids), terpenes (such as monoterpenes and diterpenoids), and phenols (such as monophenols and flavonoids), may be produced in large quantities in plant tissues due to insect attack 2,9,16,20,34,41,73. The insects that can induce plants to produce galls are called gall-forming insects and represent a large group of phytophagous insects. Galls on host plants vary morphologically among different insects 27 , these morphological differences are considered to represent the adaptability of the gall-forming insects to the environment 5,27,33. Six hypotheses have been proposed to explain this phenomenon, including the nonadaptive hypothesis,...