Kokugaryo is a historical term referring to koryo (an Imperial demesne) after around the mid-Heian period, differentiated from shoen (manor in medieval Japan). "Kokuga" means the administrative institutions in ryoseikoku (provinces).
Since around the 10th century, the tax system consisting of the ancient family registration system and handen shuju sei (a system of periodic reallocations of rice land) stipulated by the Ritsuryo system (a system of centralized government based on the ritsuryo code) had almost collapsed, gradually shifting into the kokushi ukeoi system, which made Zuryo (the head of Kokushi [provincial governors] who was sent to local provinces to administer) undertake tax collection in their provinces. Accordingly, koryo under the control of Zuryo began to be treated like their private assets. To deal with tax delinquencies designated to the main temples and shrines, and the high-ranked aristocracy including Sekkan-ke (the families which produced regents), it became customary for Zuryo to give away to those tax recipients the rights to collect taxes from parts of koryo, as an attempt to avoid poor evaluation with Zuryo koka sadame, their job performance reviews. In this way, newly-established shoen, namely, kokumen no sho (a shoen allowed exemption from rice tax or other tributes), had been vermicularly spreading within koryo, strangling the tax collection from koryo.
Especially in the 11th century, a number of fire disasters occurred in dairi (the Imperial Palace), main temples and shrines, and it was difficult to levy extraordinary taxes for their reconstruction. Therefore, Manor Regulation Acts were frequently ordered to levy taxes (Ikkoku heikinyaku [taxes and labor uniformly imposed on shoen and kokugaryo in a province]) even on kokumen no sho, which was, after all, nothing more than an accomplished fact. These Manor Regulation Acts prohibited establishment of new shoen after the designated base year, while legalizing these extraordinary taxes that were to be imposed on kokumen no sho created prior to the base year. Before that, shoen were simply agricultural lands scattered in koryo, of which the tax collection rights were exclusively possessed by the high-ranked aristocracy, main temples and shrines. However, following these orders, the government took measures to integrate shoen into one domain in an attempt to differentiate between koryo and shoen, facilitating the levy of Ikkoku heikinyaku. Thus, shoen as a governing domain was established, where a shokan (an officer governing shoen dispatched by the senior aristocracy and main temples and shrines) was delegated authority for local administration and tax collection for the nation.
Eventually, the old provincial system, administered by zuryo collectively including shoen, was shifted into a new system, in which the control of land and people was roughly divided into two on the basis of shoen (administered by shokan) and koryo (administered by zuryo). Koryo under such a system were regarded as kokuga (provincial government offices) areas controlled by zuryo, and were called kokugaryo. Also, the historian Yoshihiko AMINO advocates a concept of shoen koryo sei (The System of Public Lands and Private Estates), focusing on the fact that medieval Japanese society consisted of shoen and koryo.
After the Kamakura bakufu (Japanese feudal government headed by a shogun) was established, kokugaryo was gradually placed under the control of shugo (provincial constable) and jito (manager and lord of the manor), but still remained in the Muromachi period. Afterwards, it was effectively dismantled by taiko kenchi (the cadastral surveys conducted by Hideyoshi).