What is a .cif file?
chemical/x-cif
CIF (Crystallographic Information File) is the IUCr's standard text format for crystal structures. It is a tagged plain-text format in which `_data_name value` pairs and `loop_` blocks carry unit-cell parameters, symmetry operations, atom sites with fractional coordinates and occupancies, and full experimental provenance. mmCIF, its macromolecular profile, is now the archival format of the Protein Data Bank.
How to use a .cif file
Use an example .cif file to test crystallography parsers and structure viewers, exercising loop_ construct handling, quoted and multi-line semicolon-delimited values, and the reconstruction of Cartesian coordinates from fractional ones and the cell parameters.
Download example .cif files
- Idealised Rock-Salt Structure — Crystallographic CIF (.cif)A single-data-block CIF describing an idealised rock-salt lattice: cell parameters, space group, a symmetry-operation loop and an atom-site loop with fractional coordinates and occupancies. The '?' in the temperature field is CIF's marker for unknown, which is not the same as an empty value.
- CIF Parser Edge Cases — Quotes, Text Fields and Wrapped Loops (.cif)A CIF built entirely out of the constructs that break naive parsers: quoted values containing apostrophes and hashes, a semicolon-delimited multi-line text field, the distinct '?' and '.' markers, a standard uncertainty written as 1.2345(7), and a loop whose rows wrap across lines. Every one of them is legal CIF.