The mass of the W boson, a mediator of the weak force between elementary particles, is tightly constrained by the symmetries of the standard model of particle physics. The Higgs boson was the last missing component of the model. After the observation of the Higgs boson, a measurement of the W boson mass provides a stringent test of the model. We measure the W boson mass using data corresponding to 8.8 inverse femtobarns of integrated luminosity collected in proton-antiproton collisions at a 1.96 TeV center-of-mass energy with the CDF II detector at the Fermilab Tevatron collider. The measured value is in tension with the prediction.