The understanding of the mechanical properties in glass nanofibers remains a challenge. As the fiber diameter decreases, surface-to-volume atom fraction increases, making the impact of surface defects more significant. To elucidate these effects, we employed classical molecular dynamics (MD) simulations to investigate how fiber dimensions and the surface layer influence the mechanical properties of silica glass nanofibers. Our simulation methodology included fibers of varying diameters, generated using two different production methods (i.e. “cutting” and “casting” methods) that produce different degrees of surface atomic defects, and compared with bulk samples without surface atoms. The defect-rich surface layer of these fibers was carefully analyzed. Then, MD tensile simulations were performed to analyze the effect of the fiber surface on the mechanical properties and to explain the onset of the brittle-to-ductile transition experimentally observed at a few tens of nanometers. The results revealed that the surface layer maintains a fixed thickness independent of the fiber diameter, resulting in a pronounced increase of the fiber defects in thin fibers. Also, the tensile test simulations show that surface defects significantly reduce tensile strength, without appreciably increasing ductility compared to bulk samples. In turn, we show that the brittle-to-ductile transition is not caused by the surface defects, but related to a balance between fracture energy and elastic energy, which varies with fiber length. Using experimental values of different glass properties, our theory predicted a threshold length of around 200 nm, below which ductile fracture dominates, in reasonable agreement with experimental results.