Phase-change memory stores data by switching chalcogenide materials between high- and low-resistance states. The structure of those materials—including octahedral motifs and vacancies—helps explain how switching can become faster and require less power.