Aims. We aim to extend our current observational understanding of the integrated planet Earth spectropolarimetry from the optical to the near-infrared wavelengths. Major biomarkers like O 2 and water vapor are strong flux absorbents in the Earth's atmosphere, and some linear polarization of the reflected stellar light is expected to occur at these wavelengths. Methods. Simultaneous optical (0.4−0.9 μm) and near-infrared (0.9−2.3 μm) linear spectropolarimetric data of the earthshine were acquired by observing the nightside of the waxing Moon. The data have sufficient spectral resolution (2.51 nm in the optical, and 1.83 and 2.91 nm in the near-infrared) to resolve major molecular species present in the Earth's atmosphere. Results. We find the highest values of linear polarization (≥10%) at the bluest wavelengths, which agrees with other studies. Linear polarization intensity steadily decreases toward red wavelengths reaching a nearly flat value beyond ∼0.8 μm. In the near-infrared, we measured a polarization degree of ∼4.5 % for the continuum. We report the detection of molecular features due to O 2 at 0.760, 1.25 μm, and H 2 O at 0.653-0.725 μm, 0.780-0.825 μm, 0.93, and 1.12 μm in the spectropolarimetric data, and most of them show high linear polarimetry degrees above the continuum. In particular, the broad H 2 O 1.12 μm band displays a polarimetric intensity as high as that of the blue optical. These features may become a powerful tool for characterizing Earth-like planets in polarized light.