The invention discloses a method for preparing nano tin / carbon composite nanofibers through the electrospinning technology. The method includes the steps that first, stannous chloride, polymethyl methacrylate and polyacrylonitrile are prepared into composite nanofibers through the electrospinning technology; then calcination is conducted under the nitrogen atmosphere, so that the polyacrylonitrile is carbonized, SnCl2 is decomposed, the polymethyl methacrylate is subjected to pyrolysis, accordingly, a porous structure is formed, and the nano tin / carbon composite nanofibers are obtained. The method has the advantages that the preparation technology is simple, the reaction condition is easy to control, and the repetitive rate is high; obtained Sn particles are only 1-2 nm and are evenly inlaid N-doped porous carbon nanofibers, and the mass percent of the Sn can reach 60-65%. The composite material is of a three-dimensional net structure which is formed by interweaving nanofibers from the microcosmic view, the composite material can be directly used as the negative electrode of a sodium-ion battery without a binding agent, high electrochemistry sodium storage reversible capacity can be achieved, excellent rate capability and cycling stability are achieved, and the application prospect is very bright.