Salvadora persica is a popular medicinal plant in the Middle East countries. It is well adapted to a wide range of habitats. In this study we have compared the effect of two different habitats (Al-ahsabah valley and Shada Mountain) in Al-Baha City, south west of Saudi Arabia on the content of some primary and secondary metabolites in S. persica. The results show that soil texture, soil moisture and organic matter contents varied in the studied regions. This variation was accompanied by differences in total count and distribution of Mycorrhizal spores in both studied habitats. Soil total count of mycorrhizal spores and root colonization percentage in Shada Mountain was significantly higher than that in AlAhsabah valley. Moisture content, carbohydrates, proteins and amino acids concentrations in leaves and roots of plants collected from Al-ahsabah valley were significantly higher than those collected from Shada Mountain. Gas chromatography mass spectrometry (GC-MS) analysis showed that benzene, (isothiocyanatomethyl) was the most abundant analyt in both extracts. There was a slight variation in the secondary metabolites pattern, where benzene, 1-isocyano-2-methyl-in extract of S. persica roots collected from Al-Ahsabah valley substituted with Benzyl nitrile in S. persica roots of Shada Mountain. Taken together we could conclude that, different habitats in the studied regions affect markedly the concentration of its primary metabolites and to less extent the secondary metabolites. Isolation of the active phytochemical constituents from plants of different habitats and studding of its biological activity will definitely give fruitful results.