Background/Objectives:Agriophyllum squarrosum (L.) Moq. (A. squarrosum), also known as sandrice, is an important medicinal plant widely distributed in dunes across all the deserts of China. Common garden trials have shown content variations in flavonoids among the ecotypes of sandrice, which correlated with temperature heterogeneity in situ. However, there have not been any environmental control experiments to further elucidate whether the accumulation of flavonoids was triggered by cold stress; Methods: This study conducted a four-day ambient 4 °C low-temperature treatment on three ecotypes along with an in situ annual mean temperature gradient (Dulan (DL), Aerxiang (AEX), and Dengkou (DK)); Results: Target metabolomics showed that 12 out of 14 flavonoids in sandrice were driven by cold stress. Among them, several flavonoids were significantly up-regulated, such as naringenin and naringenin chalcone in all three ecotypes; isorhamnetin, quercetin, dihydroquercetin, and kaempferol in DL and AEX; and astragalin in DK. They were accompanied by 19 structural genes of flavonoid synthesis and 33 transcription factors were markedly triggered by cold stress in sandrice. The upstream genes, AsqAEX006535-CHS, AsqAEX016074-C4H, and AsqAEX004011-4CL, were highly correlated with the enrichment of naringenin, which could be fine-tuned by AsqAEX015868-bHLH62, AsqAEX001711-MYB12, and AsqAEX002220-MYB1R1; Conclusions: This study sheds light on how desert plants like sandrice adapt to cold stress by relying on a unique flavonoid biosynthesis mechanism that regulating the accumulation of naringenin. It also supports the precise development of sandrice for the medicinal industry. Specifically, quercetin and isorhamnetin should be targeted for development in DL and AEX, while astragalin should be precisely developed in DK.