The invention discloses eggplant potassium ion channel protein SmAKT1 as well as an encoding gene and an application thereof. The protein SmAKT1 has the amino acid sequence shown in SEQ ID NO.2, and anucleotide sequence encoding the gene of the protein is shown in SEQ ID NO.1. The gene has expression in roots, stems, leaves, flowers, fruits and sepals, and the expression quantity in a root systemis notably higher than that in other tissue. Under low-potassium and salt stress treatment, the expression quantity of the gene in the leaves and the root system has the trend of first rising and then dropping. The gene function of the protein SmAKT1 is also identified, the gene SmAKT1 is imported in a target defect type yeast strain or an arabidopsis thaliana mutant, and the stress resistance ofthe gene to low-potassium stress and salt stress can be improved. A theoretical basis is provided for cultivation of the low-potassium stress and salt stress resistant eggplants with a gene engineering technology in the future, and the gene has great application value.