Shō Shin
The three districts are based on the three kingdoms of Hokuzan, Chūzan, and Nanzan. The origin of the "magiri" system is unclear, but was solidified by the beginning of the reign of Shō Shin, the third king of the Second Shō Dynasty of the Ryukyu Kingdom who ruled between 1477 and 1526. The "magiri" were originally controlled by individual "aji", but as the Ryukyu Kingdom centralized at the turn of the 15th century the "aji" relocated to the capital of the kingdom at Shuri. After this period the title of "aji" became symbolic, and low-ranking officials were assigned the day-to-day administration of the "magiri".