Thermal decomposition of crystalline struvite provides an efficient and well controllable method for the synthesis of mesoporous phosphates.