The invention discloses a method for obtaining transgenic cotton by transforming live immature embryos mediated by Agrobacterium, which consists of the steps of peeling off aseptic embryos, preparing transformation liquid, shaking and infecting, preparing transgenic cotton, and identifying transgenic plants. In the aseptic embryo stripping, 30% hydrogen peroxide and sterile water are prepared into a disinfectant solution, the cotton seeds are plucked and put into the disinfectant solution, soaked at 25°C for 24 hours, the seeds are taken out and placed in a petri dish, and the seed coat and 1 / 3 to 1 / 2 cotyledons, and the remaining cotton embryos are placed in a petri dish containing basal medium to injure the cotton embryos; in the step of preparing the transformation solution, the induction solution is made of acetosyringone and magnesium sulfate, and acetosyringone Ketones can induce the activation of the Vir gene of Agrobacterium and improve the efficiency of exogenous gene integration; in the shaking infection step, Silwet L‑77 and MS liquid medium were added to the transformation solution to make Agrobacterium cover cotton embryos in a wider range. The invention has the advantages of easy screening, short cotton growth cycle, easy operation, transformation efficiency and the like.