The imperial examination was a civil service examination system in Imperial China designed to select the best potential candidates to serve as administrative officials, for the purpose of recruiting them for the state's bureaucracy. With the avowed purpose of testing and selecting candidates for merit, the examination system markedly influenced various aspects of society and culture in Imperial China, including Chinese mythology.
The imperial civil service examinations were designed as objective measures to evaluate the educational attainment and merit of the examinees, as part of the process by which to make selections and appointments to various offices within the structure of the government of the Chinese empire, or, sometimes, during periods of Chinese national disunion, of offices within the various states. During more recent historical times, successful candidates could receive the jinshi (chin-shih), and other degrees, generally followed by assignment to specific offices, with higher level degrees and competitive ranking within the degrees tending to lead to higher ranking placements in the imperial government service. The examination system developed largely in response to religious and philosophical ideas about ideal social order. Also, traditional Chinese religion and philosophy responded to concerns about the examination system. Both processes were intimately bound together with a literary system and other traditions which had a relative continuity of several thousand years. The actual examination process developed together with various related philosophical, religious, and narrative concepts to produce a distinct mythological motif.