Typesetting Nucleobases in LaTeX with chemfig

This page is thought to be a personal reminder on how to draw nucleobases in LaTeX with the chemfig package. In the reference manual there is just the guanine example. Since we want to have all DNA and RNA bases, here is the complete list of them!

Standard nucleobases

My suggestion is to set \setchemfig{atom sep=2.em} before the figures, because with LaTeX’s default parameters the bonds are too long and not that aestetic.

Modified nucleobases

Work in progress…


  1. Hypoxanthine is a naturally occurring purine derivative. It is occasionally found as a constituent of nucleic acids, where it is present in the anticodon of tRNA in the form of its nucleoside inosine. ↩︎

  2. Stolen and adapted from the reference manual↩︎