A Shogun ("general", literally "military commander") was a hereditary military dictator in Japan during the period from 1192 to 1867, with some caveats. In this period, the shoguns were the de facto rulers of the country, although nominally they were appointed by the Emperor as a formality. The Shogun held almost absolute power over territories through military means, in contrast to the concept of a colonial governor in Western culture who was appointed by a king. Nevertheless, an unusual situation occurred during the Kamakura period (1199-1333) upon the death of the first shogun, whereby the Hōjō clan's hereditary titles of Shikken and Tokuso (1256-1333) monopolized the shogunate, collectively deemed as the Regent Rule. The actual shogun during this period met the same fate as the Emperor and was reduced to a figurehead until a coup in 1333, in which retainers restored power to the shogun.
The modern rank of shogun is roughly equivalent to a generalissimo. The title is the short form of Sei-i Taishōgun (literally "Commander-in-Chief of the Expeditionary Force Against the Barbarians"); the individual governing the country at various times in the history of Japan, ending when Tokugawa Yoshinobu relinquished the office to the Meiji Emperor in 1867.
A shogun's office or administration is the shogunate, known in Japanese as the bakufu (literally "tent office/government"), which originally referred to house of the general and later also suggested a private government under a shogun. The tent symbolized the field commander but also denoted that such an office was meant to be temporary. The shogun's officials were as a collective the bakufu, and were those who carried out the actual duties of administration while the imperial court retained only nominal authority. In this context, the office of the shōgun had a status equivalent to that of a viceroy or governor-general, but in reality shōguns dictated orders to everyone including the reigning Emperor.