Self-assembly to create molecular and nanostructures is typically performed at the thermodynamic minimum. To achieve dynamic functionalities, such as adaptability, internal feedback, and self-replication, there is a growing focus on out-of-equilibrium systems. This report presents the dynamic self-assembly of an artificial host–guest system at an interface, under control by a dissipative electrochemical process using (electrical) energy, resulting in an out-of-equilibrium system exhibiting a supramolecular surface gradient. The gradient, its steepness, rate of formation, and complex surface composition after backfilling, as well as the surface compositions after switching between the different states of the system, are assessed and supported by modelling. Our method shows for the first time an artificial surface-confined out-of-equilibrium system. The electrochemical process parameters provide not only control over the system in time, but also in space.