Mg2C21PH13O8 crystallizes in the monoclinic P2_1/c space group. There are two inequivalent Mg sites. In the first Mg site, Mg(1) is bonded to one O(1), one O(3), one O(4), one O(7), and one O(8) atom to form MgO5 square pyramids that share corners with two equivalent Mg(2)O5 square pyramids and  a cornercorner with one P(1)C3O tetrahedra. The Mg(1)-O(1) bond length is 2.07 Å. The Mg(1)-O(3) bond length is 2.10 Å. The Mg(1)-O(4) bond length is 2.06 Å. The Mg(1)-O(7) bond length is 2.07 Å. The Mg(1)-O(8) bond length is 2.03 Å. In the second Mg site, Mg(2) is bonded to one O(2), one O(5), one O(6), and two equivalent O(8) atoms to form a mixture of edge and corner-sharing MgO5 square pyramids. The Mg(2)-O(2) bond length is 2.08 Å. The Mg(2)-O(5) bond length is 2.09 Å. The Mg(2)-O(6) bond length is 2.07 Å. There is one shorter (2.06 Å) and one longer (2.07 Å) Mg(2)-O(8) bond length. There are twenty-one inequivalent C sites. In the first C site, C(1) is bonded in a trigonal planar geometry to one C(2), one C(6), and one P(1) atom. The C(1)-C(2) bond length is 1.37 Å. The C(1)-C(6) bond length is 1.40 Å. The C(1)-P(1) bond length is 1.81 Å. In the second C site, C(2) is bonded in a distorted single-bond geometry to one C(1) and one H(2) atom. The C(2)-H(2) bond length is 0.95 Å. In the third C site, C(3) is bonded in a distorted single-bond geometry to one C(4) and one H(3) atom. The C(3)-C(4) bond length is 1.39 Å. The C(3)-H(3) bond length is 0.95 Å. In the fourth C site, C(4) is bonded in a trigonal planar geometry to one C(3), one C(5), and one C(7) atom. The C(4)-C(5) bond length is 1.37 Å. The C(4)-C(7) bond length is 1.51 Å. In the fifth C site, C(5) is bonded in a distorted trigonal planar geometry to one C(4), one C(6), and one H(4) atom. The C(5)-C(6) bond length is 1.38 Å. The C(5)-H(4) bond length is 0.95 Å. In the sixth C site, C(6) is bonded in a distorted single-bond geometry to one C(1), one C(5), and one H(5) atom. The C(6)-H(5) bond length is 0.95 Å. In the seventh C site, C(7) is bonded in a distorted bent 120 degrees geometry to one C(4), one O(2), and one O(3) atom. The C(7)-O(2) bond length is 1.24 Å. The C(7)-O(3) bond length is 1.27 Å. In the eighth C site, C(8) is bonded in a trigonal planar geometry to one C(13), one C(9), and one P(1) atom. The C(8)-C(13) bond length is 1.39 Å. The C(8)-C(9) bond length is 1.38 Å. The C(8)-P(1) bond length is 1.80 Å. In the ninth C site, C(9) is bonded in a distorted trigonal planar geometry to one C(10), one C(8), and one H(6) atom. The C(9)-C(10) bond length is 1.39 Å. The C(9)-H(6) bond length is 0.95 Å. In the tenth C site, C(10) is bonded in a distorted trigonal planar geometry to one C(11), one C(9), and one H(7) atom. The C(10)-C(11) bond length is 1.36 Å. The C(10)-H(7) bond length is 0.95 Å. In the eleventh C site, C(11) is bonded in a trigonal planar geometry to one C(10), one C(12), and one C(14) atom. The C(11)-C(12) bond length is 1.38 Å. The C(11)-C(14) bond length is 1.53 Å. In the twelfth C site, C(12) is bonded in a distorted single-bond geometry to one C(11) and one H(8) atom. The C(12)-H(8) bond length is 0.95 Å. In the thirteenth C site, C(13) is bonded in a distorted single-bond geometry to one C(8) and one H(9) atom. The C(13)-H(9) bond length is 0.95 Å. In the fourteenth C site, C(14) is bonded in a distorted bent 120 degrees geometry to one C(11), one O(4), and one O(5) atom. The C(14)-O(4) bond length is 1.26 Å. The C(14)-O(5) bond length is 1.24 Å. In the fifteenth C site, C(15) is bonded in a trigonal planar geometry to one C(16), one C(20), and one P(1) atom. The C(15)-C(16) bond length is 1.38 Å. The C(15)-C(20) bond length is 1.40 Å. The C(15)-P(1) bond length is 1.81 Å. In the sixteenth C site, C(16) is bonded in a distorted single-bond geometry to one C(15), one C(17), and one H(10) atom. The C(16)-C(17) bond length is 1.38 Å. The C(16)-H(10) bond length is 0.95 Å. In the seventeenth C site, C(17) is bonded in a distorted trigonal planar geometry to one C(16), one C(18), and one H(11) atom. The C(17)-C(18) bond length is 1.39 Å. The C(17)-H(11) bond length is 0.95 Å. In the eighteenth C site, C(18) is bonded in a trigonal planar geometry to one C(17), one C(19), and one C(21) atom. The C(18)-C(19) bond length is 1.39 Å. The C(18)-C(21) bond length is 1.51 Å. In the nineteenth C site, C(19) is bonded in a distorted single-bond geometry to one C(18) and one H(12) atom. The C(19)-H(12) bond length is 0.95 Å. In the twentieth C site, C(20) is bonded in a distorted single-bond geometry to one C(15) and one H(13) atom. The C(20)-H(13) bond length is 0.95 Å. In the twenty-first C site, C(21) is bonded in a distorted bent 120 degrees geometry to one C(18), one O(6), and one O(7) atom. The C(21)-O(6) bond length is 1.26 Å. The C(21)-O(7) bond length is 1.25 Å. P(1) is bonded to one C(1), one C(15), one C(8), and one O(1) atom to form PC3O tetrahedra that share  a cornercorner with one Mg(1)O5 square pyramid. The P(1)-O(1) bond length is 1.49 Å. There are thirteen inequivalent H sites. In the first H site, H(1) is bonded in a single-bond geometry to one O(8) atom. The H(1)-O(8) bond length is 1.00 Å. In the second H site, H(2) is bonded in a single-bond geometry to one C(2) atom. In the third H site, H(3) is bonded in a single-bond geometry to one C(3) atom. In the fourth H site, H(4) is bonded in a single-bond geometry to one C(5) atom. In the fifth H site, H(5) is bonded in a single-bond geometry to one C(6) atom. In the sixth H site, H(6) is bonded in a single-bond geometry to one C(9) atom. In the seventh H site, H(7) is bonded in a single-bond geometry to one C(10) atom. In the eighth H site, H(8) is bonded in a single-bond geometry to one C(12) atom. In the ninth H site, H(9) is bonded in a single-bond geometry to one C(13) atom. In the tenth H site, H(10) is bonded in a single-bond geometry to one C(16) atom. In the eleventh H site, H(11) is bonded in a single-bond geometry to one C(17) atom. In the twelfth H site, H(12) is bonded in a single-bond geometry to one C(19) atom. In the thirteenth H site, H(13) is bonded in a single-bond geometry to one C(20) atom. There are eight inequivalent O sites. In the first O site, O(1) is bonded in a bent 150 degrees geometry to one Mg(1) and one P(1) atom. In the second O site, O(2) is bonded in a distorted bent 120 degrees geometry to one Mg(2) and one C(7) atom. In the third O site, O(3) is bonded in a bent 120 degrees geometry to one Mg(1) and one C(7) atom. In the fourth O site, O(4) is bonded in a distorted bent 150 degrees geometry to one Mg(1) and one C(14) atom. In the fifth O site, O(5) is bonded in a distorted bent 120 degrees geometry to one Mg(2) and one C(14) atom. In the sixth O site, O(6) is bonded in a bent 120 degrees geometry to one Mg(2) and one C(21) atom. In the seventh O site, O(7) is bonded in a distorted bent 150 degrees geometry to one Mg(1) and one C(21) atom. In the eighth O site, O(8) is bonded to one Mg(1), two equivalent Mg(2), and one H(1) atom to form distorted edge-sharing OMg3H tetrahedra. Linkers: 4 [O]C(=O)c1ccc(P(=O)(c2ccc(C([O])=O)cc2)c2ccc(C([O])=O)cc2)cc1. Metal clusters: 2 O=[C]O[Mg].O=[C]O[Mg].O=[C]O[Mg]O.O=[C]O[Mg]O.[O].[O].[O][C]=O.[O][C]=O. RCSR code: flu. The MOF has largest included sphere 8.66 A, density 0.83 g/cm3, surface area 4497.22 m2/g, accessible volume 0.67 cm3/g