Charged domain walls in ferroelectrics are interesting as they may enhance electrical conductivity. Here, atomic-resolution imaging of Ca3–xSrxTi2O7 reveals that charged domain boundaries are stabilized by an out-of-phase translational shift of crystallographic domains and that Sr ions accumulate at the boundaries.