The Directorate of Education (guozijian 國子監) was the highest administrative unit for all educational institutions in traditional China. It mainly served for the education of state officials. Its origins reach back to the Jin period 晉 (265-420 CE) when Emperor Wu 晉武帝 (r. 265-289) first appointed a Chancellor (guozi jijiu 國子祭酒, literally "libationer") and an erudite (boshi 博士) as administrators and head teachers of the "School for the Sons of the State" (i. e., the Princes, guozixue 國子學).
During the Northern Qi period 北齊 (550-577) the institution was renamed Court for Education (guozisi 國子寺). Emperor Wen 隋文帝 (r. 581-604) of the Sui dynasty 隋 (581-618) abolished this institution in favour to the National University (taixue 太學). His successor, Emperor Yang 隋煬帝 (r. 604-617), revived the Directorate of Education.
During the Tang period 唐 (618-907) the Directorate of Education was divided into six sections, each headed by an erudite: The "School for the Sons of the State" (guozixue 國子學), the National University (taixue), the School of the Four Gates of the Capital (simenxue 四門學) open to sons of lesser nobles and officials and to some specially gifted sons of commoners, the Law and Arithmetics School (lüsuanxue 律算學), and the Calligraphy School (shuxue 書學). Each of these sections was headed by a Chancellor and had the primary task to educate the Heir Apparent. In 661 a parallel Directorate was established in the Eastern Capital Luoyang 洛陽 (today in Henan). The guozijian was then also known with the designation Academy of the Rector (sichengguan 司成館 or chengjunjian 成均監).
During the Song period 宋 (960-1279) the Directorate was subordinated to the Ministry of Rites (libu 禮部) and allowed enrolment only to sons and brothers of officials that occupied a position of the seventh official rank and upwards. With the reorganisation of the National University in the 1070s the Directorate of Education became the central administrative institution for all official schools throughout the empire, including the National University, the "School for the Sons of the State", the military schools (wuxue 武學), law schools (lüxue 律學), elementary schools (xiaoxue 小學) and prefectural (zhouxue 州學) and district schools (xianxue 縣學). It supervised the promotion of the best graduates, the building and furnishing of schools, the providing of charts and figures on the three rituals (sanli tu 三禮圖) and of images of the sages of the past (shengxian xiang 聖賢像), the construction of libraries, and organised the inspection of schools by the emperor. At the beginning of the Song period the Directorate was headed by a Supervisor (panjianshi 判監事) who was assisted by a Lecturer (zhijiang 直講), an aide (cheng 丞) and a recorder (zhubu 主簿).
In 1080 the Supervisor was replaced by a Chancellor (guozi jijiu) who was assisted by a Director of Studies (siye 司業). The Lecturer was replaced by an erudite of the National University (taixue boshi 太學博士). The other educational divisions were headed by an Instructor Second-Class (xuezheng 學正), a Provost (xuelu 學錄), and two erudites for the military schools and the law schools, respectively. The inner administration of the Directorate was divided into three sections. The monetary funds, grain reserves and the textbooks were supervised by the Kitchen-and-Storehouse Section (chuku'an 廚庫案); enrolment, examinations and promotions were supervised by the Educational Section (xue'an 學案); and miscellaneous things were administered by the Miscellaneous Section (zhiza'an 知雜案). Each section was headed by a Chief of Assistants (xuzhang 胥長) who supervised the subofficial functionaries (xuzuo 胥佐) and writers (tieshu 貼書). The Directorate also disposed of a library and a printing shop to provide the court with all necessary documents edited under its supervision. The books published by the Directorate are called "Directorate editions" (jianben 監本). These editions are often of a supreme quality and served as model prints for copies made throughout the empire.
In all three secondary capitals of the Northern Song empire 北宋 (960-1126), Songzhou 宋州 (Yingtian 應天, modern Shangqiu 商丘, Henan), Henan 河南 (modern Luoyang) and Daming 大名 (modern Daming, Hebei), a parallel structure of Directorates was established that was reduced in 1105. From then on, there was only one Chancellor, and the branch offices were administered by a Director of Studies. During that time it was rarely the case that high officials had passed the examinations in the Directorate of Education. It was only an administrative instrument.
The government of the Liao 遼 (907-1125) and Jin 金 (1115-1234) empires also established Directorates of Eduction with a similar structure of the central administration. There was a special aide in the administration of the Jin dynasty Directorate who supervised the Jurchen schools. The Yuan dynasty 元 (1279-1368) even established a specialized Directorate of Education for Mongols (Menggu guozijian 蒙古國子監) and one for Uighurs (Huihui guozijian 回回國子監).
The Ming dynasty 明 (1368-1644) had two Directorates of Education after the transferral of the main capital from Nanjing to Beijing in 1403. Both had the same structure and were administered by a Chancellor, a Director of Studies, a Proctor (jiancheng 監丞) and an archivist (dianbu 典簿).
The Qing dynasty 清 (1644-1911) returned to a single central institution in Beijing that oversaw all public schools of the empire except the School for the Imperial Family (zongxue 宗學) and the School for the Gioro Tribe (Jueluoxue 覺羅學). The Directorate was headed by a Grand Minister Supervisor of the Directorate (guanli jianshi dachen 管理監事大臣), two Chancellors (one a Manchu and one Chinese), and three Directors of Studies (a Manchu, a Mongol and a Chinese). The Directorate of Education was abolished in 1907, and the supervision of schools was put into the hands of the Ministry of Education (xuebu 學部).