Effector genes, together with climatic and other environmental factors, play multifaceted roles in the development of plant diseases. Understanding the role of environmental factors, particularly climate conditions affecting the evolution of effector genes, is important for predicting the long-term value of the genes in controlling agricultural diseases. Here, we collected Phytophthora infestans populations from five locations along a mountainous hill in China and sequenced the effector gene Pi02860 from >300 isolates. To minimize the influence of other ecological factors, isolates were sampled from the same potato cultivar on the same day. We also expressed the gene to visualise its cellular location, assayed its pathogenicity and evaluated its response to experimental temperatures. We found that Pi02860 exhibited moderate genetic variation at the nucleotide level which was mainly generated by point mutation. The mutations did not change the cellular location of the effector gene but significantly modified the fitness of P. infestans. Genetic variation and pathogenicity of the effector gene were positively associated with the altitude of sample sites, possibly due to increased mutation rate induced by the vertical distribution of environmental factors such as UV radiation and temperature. We further found that Pi02860 expression was regulated by experimental temperature with reduced expression as experimental temperature increased. Together, these results indicate that UV radiation and temperature are important environmental factors regulating the evolution of effector genes and provide us with considerable insight as to their future sustainable action under climate and other environmental change.