Ensembles of active magnetic colloids demonstrate complex collective behavior and self-organization when driven out of equilibrium by external magnetic fields. The interplay between magnetic and hydrodynamic interactions often result in spontaneous self-assembly and the emergence of localized vortices in ensembles of ferromagnetic rollers. We report experimental and computational study of the self-organized multi-vortical state in ensembles of magnetic rollers under the imposed external confining potential realized by patterned substrates. We explore the behavior of the system on a substrate patterned with shallow wells ordered in a lattice with square symmetry and lattice spacing smaller than the wells’ diameter. We demonstrate, that ensembles of active magnetic rollers evolve in response to changes in the geometry of the confining lattice from a globally correlated state characterized by anti-ferromagnetic vortex ordering to a state with rapidly changing particle flows and self-organized vortical states with a lattice constant larger than one of the confining pattern. Our experimental observations are accompanied by numerical simulations based on phenomenological coarse grained particle dynamics coupled to Navier–Stokes hydrodynamics in shallow water approximation. The reported results provide insights into the collective behavior of active magnetic rollers under confinement and suggest strategies for the manipulation of collective dynamic states in active magnetic liquids.