Coordination polymer nanorods are synthesized from the hexagonal 3D structure of Fe-MIL-88B. Subsequently, hematite (α-Fe2O3) and magnetite (Fe3O4) nanorods are selectively prepared by controlling the calcination conditions of coordination polymer nanorods.