stylistic:tone, structural:summarization, quality:corruption
Rise of the military class

Under the early courts, when military conscription had been centrally controlled, military affairs had been taken out of the hands of the provincial aristocracy. But as the system broke down after 792, local power holders again became the primary source of military strength. The re-establishment of an efficient military system was made gradually through a process of trial-and-error. At that time the imperial court did not possess an army but rather relied on an organization of professional warriors composed mainly of oryoshi, which were appointed to an individual province and tsuibushi, which were appointed over imperial circuits or for specific tasks. This gave rise to the Japanese military class. Nonetheless, final authority rested with the imperial court.

Shōen holders had access to manpower and, as they obtained improved military technology (such as new training methods, more powerful bows, armor, horses, and superior swords) and faced worsening local conditions in the ninth century, military service became part of shōen life. Not only the shōen but also civil and religious institutions formed private guard units to protect themselves. Gradually, the provincial upper class was transformed into a new military elite of samurai.

Bushi interests were diverse, cutting across old power structures to form new associations in the tenth century. Mutual interests, family connections, and kinship were consolidated in military groups that became part of family administration. In time, large regional military families formed around members of the court aristocracy who had become prominent provincial figures. These military families gained prestige from connections to the imperial court and court-granted military titles and access to manpower. The Fujiwara family, Taira clan, and Minamoto clan were among the most prominent families supported by the new military class.

A decline in food production, the growth of the population, and competition for resources among the great families all led to the gradual decline of Fujiwara power and gave rise to military disturbances in the mid-tenth and eleventh centuries. Members of the Fujiwara, Taira, and Minamoto families—all of whom had descended from the imperial family—attacked one another, claimed control over vast tracts of conquered land, set up rival regimes, and generally upset the peace.

The Fujiwara controlled the throne until the reign of Emperor Go-Sanjō (1068–1073), the first emperor not born of a Fujiwara mother since the ninth century. Go-Sanjo, determined to restore imperial control through strong personal rule, implemented reforms to curb Fujiwara influence. He also established an office to compile and validate estate records with the aim of reasserting central control. Many shōen were not properly certified, and large landholders, like the Fujiwara, felt threatened with the loss of their lands. Go-Sanjo also established the In-no-chō (院庁 "Office of the Cloistered Emperor"), which was held by a succession of emperors who abdicated to devote themselves to behind-the-scenes governance, or insei.

The In-no-chō filled the void left by the decline of Fujiwara power. Rather than being banished, the Fujiwara were mostly retained in their old positions of civil dictator and minister of the center while being bypassed in decision making. In time, many of the Fujiwara were replaced, mostly by members of the rising Minamoto clan. While the Fujiwara fell into disputes among themselves and formed northern and southern factions, the insei system allowed the paternal line of the imperial family to gain influence over the throne. The period from 1086 to 1156 was the age of supremacy of the In-no-chō and of the rise of the military class throughout the country. Military might rather than civil authority dominated the government.

A struggle for succession in the mid-twelfth century gave the Fujiwara an opportunity to regain their former power. Fujiwara no Yorinaga sided with the retired emperor in a violent battle in 1156 against the heir apparent, who was supported by the Taira and Minamoto (Hōgen Rebellion). In the end, the Fujiwara were destroyed, the old system of government supplanted, and the insei system left powerless as bushi took control of court affairs, marking a turning point in Japanese history. In 1159, the Taira and Minamoto clashed (Heiji Rebellion), and a twenty-year period of Taira ascendancy began.

Taira no Kiyomori emerged as the real power in Japan following the Fujiwara's destruction, and he would remain in command for the next 20 years. He gave his daughter Tokuko in marriage to the young emperor Takakura, who died at only 19, leaving their infant son Antoku to succeed to the throne. Kiyomori filled no less than 50 government posts with his relatives, rebuilt the Inland Sea, and encouraged trade with Song China. He also took aggressive actions to safeguard his power when necessary, including the removal and exile of 45 court officials and the razing of two troublesome temples, Todai-ji and Kofuku-ji.

The Taira were seduced by court life and ignored problems in the provinces, where the Minamoto clan were rebuilding their strength. In 1183, two years after Kiyomori's death, Yoritomo Minamoto dispatched his brothers Yoshitsune and Noriyori to attack Kyoto. The Taira were routed and forced to flee, and the Empress Dowager tried to drown herself and the 6-year old Emperor. He perished, but his mother survived. Takakura's other son succeeded as Emperor Go-Toba.

With Yoritomo firmly established, the bakufu system that governed Japan for the next seven centuries was in place. He appointed military governors, or shugo, to rule over the provinces, and stewards, or jito to supervise public and private estates. Yoritomo then turned his attention to the elimination of the powerful Fujiwara family, which sheltered his rebellious brother Yoshitsune. Three years later, he was appointed shōgun in Kyoto. One year before his death in 1199, Yoritomo expelled the teenaged emperor Go-Toba from the throne. Two of Go-Toba's sons succeeded him, but they would also be removed by Yoritomo's successors to the shogunate.