Following the earlier national history Shoku Nihongi (797), in 819 Emperor Saga ordered the compilation of the years since then. Primarily edited by Fujiwara no Otsugu, Minamoto no Tokiwa, Fujiwara no Yoshino and Fujiwara no Yoshifusa, the text was completed in 840.
Much of the text was lost during the Ōnin and Bunmei Wars in the late 15th century. Of the original 40 volumes, only ten currently exist: 5, 8, 12, 13, 14, 17, 20–22, and 24.
Written in kanbun-style, the contents covered the years 792 through 833. It spans four imperial reigns: Kanmu, Heizei, Saga, Junna. The text is characteristic in that it contains criticism of emperors and officials as well as poetry.
- Ruijū Kokushi, a categorized and chronological history text of the Six National Histories; valuable resource in recreating the missing contents of the Nihon Kōki