To improve the quality of structural images and the quantification of ventilation in free-breathing dynamic pulmonary MRI. A 3D radial ultrashort TE (UTE) sequence with superior-inferior navigators was used to acquire pulmonary data during free breathing. All acquired data were binned into different motion states according to the respiratory signal extracted from superior-inferior navigators. Motion-resolved images were reconstructed using eXtra-Dimensional (XD) UTE reconstruction. The initial motion fields were generated by registering images at each motion state to other motion states in motion-resolved images. A motion-state weighted motion-compensation (MostMoCo) reconstruction algorithm was proposed to reconstruct the dynamic UTE images. This technique, termed as MostMoCo-UTE, was compared with XD-UTE and iterative motion-compensation (iMoCo) on a porcine lung and 10 subjects. MostMoCo reconstruction provides higher peak SNR (37.0 vs. 35.4 and 34.2) and structural similarity (0.964 vs. 0.931 and 0.947) compared to XD-UTE and iMoCo in the porcine lung experiment. Higher apparent SNR and contrast-to-noise ratio are achieved using MostMoCo in the human experiment. MostMoCo reconstruction better preserves the temporal variations of signal intensity of parenchyma compared to iMoCo, shows reduced random noise and improved sharpness of anatomical structures compared to XD-UTE. In the porcine lung experiment, the quantification of ventilation using MostMoCo images is more accurate than that using XD-UTE and iMoCo images. The proposed MostMoCo-UTE provides improved quality of structural images and quantification of ventilation for free-breathing pulmonary MRI. It has the potential for the detection of structural and functional disorders of the lung in clinical settings.