The precision measurement of the mass of the $W$ boson is an important goal of the Fermilab Tevatron and the CERN Large Hadron Collider (LHC). It requires accurate theoretical calculations which incorporate both higher-order QCD and electroweak corrections, and also provide an interface to parton-shower Monte Carlo programs which make it possible to realistically simulate experimental data. In this paper, we present a combination of the full ${cal O}(alpha)$ electroweak corrections of {tt WGRAD2}, and the next-to-leading order QCD radiative corrections to $Wtoell u$ production in hadronic collisions in a single event generator based on the {tt POWHEG} framework, which is able to interface with the parton-shower Monte Carlo programs {tt Pythia} and {tt Herwig}. Using this new combined QCD+EW Monte Carlo program for $W$ production we provide numerical results for total cross sections and kinematic distributions of relevance to the $W$ mass measurement at the Tevatron and the LHC for the processes $pp,pbar p to W^pm to mu^pm u_mu$. In particular, we discuss the impact of EW corrections in the presence of QCD effects when including detector resolution effects.