The cycle life and energy density of rechargeable metal batteries are largely limited by the dendritic growth of their metal anodes (lithium, sodium or zinc). Here we develop a three-dimensional cross-linked polyethylenimine lithium-ion-affinity sponge as the lithium metal anode host to mitigate the problem. We show that electrokinetic surface conduction and electro-osmosis within the high-zeta-potential sponge change the concentration and current density profiles, which enables dendrite-free plating/stripping of lithium with a high Coulombic efficiency at high deposition capacities and current densities, even at low temperatures. The use of a lithium-hosting sponge leads to a significantly improved cycling stability of lithium metal batteries with a limited amount of lithium (for example, the areal lithium ratio of negative to positive electrodes is 0.6) at a commercial-level areal capacity. We also observed dendrite-free morphology in sodium and zinc anodes, which indicates a broader promise of this approach.