We investigate axial charge production in two-color QCD out of equilibrium. We compute the real-time evolution starting with spatially homogeneous strong gauge fields, while the fermions are in vacuum. The idealized class of initial conditions is motivated by glasma flux tubes in the context of heavy-ion collisions. We focus on axial charge production at early times, where important aspects of the anomalous dynamics can be derived analytically. This is compared to real-time lattice simulations. Quark production at early times leading to anomalous charge generation is investigated using Wilson fermions. Our results indicate that coherent gauge fields can transiently produce significant amounts of axial charge density, while part of the induced charges persist to be present even well beyond characteristic decoherence times. The comparisons to analytic results provide stringent tests of real-time representations of the axial anomaly on the lattice.