The standard model for the origin of galactic magnetic fields is through the amplification of seed fields via dynamo or turbulent processes to the level consistent with present observations. Although other mechanisms may also operate, currents from misaligned pressure and temperature gradients (the Biermann battery process) inevitably accompany the formation of galaxies in the absence of a primordial field. Driven by geometrical asymmetries in shocks associated with the collapse of protogalactic structures, the Biermann battery is believed to generate tiny seed fields to a level of about 10 gauss (refs 7, 8). With the advent of high-power laser systems in the past two decades, a new area of research has opened in which, using simple scaling relations, astrophysical environments can effectively be reproduced in the laboratory. Here we report the results of an experiment that produced seed magnetic fields by the Biermann battery effect. We show that these results can be scaled to the intergalactic medium, where turbulence, acting on timescales of around 700 million years, can amplify the seed fields sufficiently to affect galaxy evolution.