In order to research the potential pollution characteristics of heavy metals in farmland, from 2004 to 2011, the author sampled heilu soil, loessial soil, and so on 6 soil types, including 147 soil samples, detected 5 kinds of heavy metal content, which were As, Hg, Pb, Cr, Cd, in farmland of Pingliang City of Gansu Province, and the potential ecological risk and pollution degree of the heavy metals in farmland were evaluated using Hakanson ecological risk index. The results showed that: the average content of As, Hg, Pb, Cr, Cd were 9.96, 0.038, 32.16, 65.98 and 0.119 mg/kg, the coefficient of variation were 30.72%, 93.94%, 47.72%, 28.36% and 60.84%, the potential ecological risk coefficient were 3.09-18.04, 3.85-323.88, 1.19-30.90, 0.46-3.22, 3.96-100.85, 6 soil farmland risk indexes were 29.21-356.69. The distribution of Hg, Cd was not uniform, while As, Pb, Cr was relatively uniform, so the soil heavy metal in farmland had potential ecological risk, Hg, Cd had bigger risk.