BACKGROUND The contents of many heavy metals in soil in many areas of southwest China are much higher than the national soil background value, and related studies show that most heavy metals in soil are in a state of “high background and low activity”, which is closely related to the special geological process in the area. Most scholars have concentrated more on the weathering process and post-weathering heavy metals of granite, basalt, carbonate rocks and other geological bodies with high background value of heavy metals in southwest China. However, alkali-enriched porphyry also has the characteristics of high background value of heavy metals, and the geochemical behavior characteristics of heavy metals in the weathering process of alkali-enriched porphyry are less studied. The ecological and environmental effects of heavy metal element migration and transformation during weathering are still unclear. There is a large-scale alkali-enriched porphyry belt located in southwest China. Most of the alkali-enriched porphyry areas have precious metals such as gold and silver, and polymetallic deposits such as copper, lead and zinc. Therefore, soil in alkali-enriched porphyry areas usually has the characteristic of high background value of heavy metals. OBJECTIVES For identifying geochemical characteristics of heavy metal elements and a series of ecological and environmental problems during the soil-forming process of alkali-enriched porphyry, to provide a scientific basis for the prevention and control of heavy metal pollution in alkali-enriched porphyry areas and rational planning of agricultural planting. METHODS For sufficient hydrothermal conditions and strong soil-forming in Yunnan Province, a rock weathering profile of Yao’an alkali-enriched porphyry in central Yunnan Province was selected as the research object. The contents of As, Cd, Cr, Cu, Hg, Ni, Pb, Zn, Al2O3, TFe2O3, CaO, Na2O, K2O, MgO, SiO2, organic carbon and pH in rock/soil samples were determined by inductively coupled plasma-mass spectrometry/optimal emission spectrometry (ICP-MS/OES), atomic fluorescence spectrometry (AFS), X-ray fluorescence spectrometry (XRF) and volumetric method. Multivariate statistics method and mass migration coefficient were used to study the distribution characteristics, migration and enrichment rules of heavy metal elements in the weathering profile, as well as the factors affecting the migration and enrichment of heavy metals. RESULTS Based on the analysis of the content and distribution characteristics of eight heavy metals in the weathering profile of Yao’an alkali-enriched porphyry, the migration and enrichment mechanism of heavy metals during the weathering process was identified, and the environmental risk assessment of the surface soil in the area was carried out. (1) In the weathering profile, all the weathering strata have the same source as the bedrock material, and there is no exogenous addition. Different degrees of desiliconization and aluminum-iron enrichment occur in the whole weathering process, especially in the surface layer. In the bottom-up evolution process, all of the heavy metal elements except Cd show an overall trend of increasing content. As, Cr, Cu, Hg and Ni are enriched to different degrees during weathering, while Cd, Pb and Zn are leaching out. The order of heavy metal migration capacity from strong to weak is Cd>Zn>Pb>Hg>Cu>As>Ni>Cr. As, Cr, Cu, and Hg have similar geochemical behavior, as do Cd, Pb, and Zn. (2) Cd, Pb and Zn occur mainly in feldspar minerals and lead-zinc metallic minerals and exhibit the characteristics of migration and leaching under acidic and strong leaching conditions. Although the bedrock is obviously deficient in Cu, Cr, Ni and Hg, it is eventually enrichedin-situ in clay minerals and Al and Fe oxides/hydroxides with weathering due to its own chemical properties and the effect of desilication to enrich aluminum and iron. The enrichment of As is mainly controlled by aluminum-Fe enrichment, and the strong aluminum-Fe enrichment in the study area results in the in-situ secondary enrichment of As. (3) The soil ecological environment in the study area may be polluted by As and Pb due to the high content of Pb in the bedrock and the effect of aluminum-iron enrichment. CONCLUSIONS The risk of As and Pb pollution may exist in the soil ecological environment of the study area, and a large amount of Pb leaching may migrate into the Dragonling River with surface runoff. It is necessary to strengthen the monitoring of heavy metals such as As and Pb in the overlying soil of alkali-enriched porphyry and heavy metals such as Pb and Zn in the rivers around alkali-enriched porphyry so as to ensure ecological safety.