We show that the Kibble-Zurek mechanism applies to nonequilibrium phase transitions found in driven assemblies of superconducting vortices and colloids moving over quenched disorder where a transition occurs from a plastic disordered flowing state to a moving anisotropic crystal. We measure the density of topological defects as a function of quench rate through the nonequilibrium phase transition, and find that on the ordered side of the transition, the topological defect density ρd scales as a power law, $${\rho }_{{{{{{{{\rm{d}}}}}}}}}\propto 1/{t}_{{{{{{{{\rm{q}}}}}}}}}^{\beta }$$
ρ
d
∝
1
/
t
q
β
, where tq is the quench time duration, consistent with the Kibble-Zurek mechanism. We show that scaling with the same exponent holds for varied strengths of quenched disorder and that the exponents fall in the directed percolation universality class. Our results suggest that the Kibble-Zurek mechanism can be applied to the broader class of systems that exhibit absorbing phase transitions.