  We show that the baryon asymmetry of the universe can be explained in models
where the Higgs couples to the Chern-Simons term of the hypercharge group and
is away from the late-time minimum of its potential during inflation. The Higgs
then relaxes toward this minimum once inflation ends which leads to the
production of (hyper)magnetic helicity. We discuss the conditions under which
this helicity can be approximately conserved during its joint evolution with
the thermal plasma. At the electroweak phase transition the helicity is then
converted into a baryon asymmetry by virtue of the chiral anomaly in the
standard model. We propose a simple model which realizes this mechanism and
show that the observed baryon asymmetry of the universe can be reproduced.
