By 900 AD the Yoruba city-state of Ile Ife established itself as the dominate power in the land of the Yoruba (central and southwest Nigeria, Benin, and Togo)though complex states existed throughout the region. The city of Ile Ife, inhabitated by Yoruba in the 4th Century BCE, became the culture center of the people. In theory, Yoruba city-states largely acknowledged the primacy of the ancient city of Ile Ife. The southeastern Benin Empire, ruled by a dynasty that traced its ancestry to Ifẹ and Oduduwa but largely populated by the Ẹdo and other related ethnicities, also held considerable sway in the election of nobles and kings in eastern Yorubaland.
Most of the city states were controlled by monarchs (Obas) and councils made up of nobles, guild leaders, and merchants. Different states saw differing ratios of power between the two. Some had powerful, semi-autocratic monarchs with almost total control, while in others the senatorial councils were supreme and the Ọba served as a figurehead. In all cases, Yoruba monarchs were always subject to the continuing approval of their constituents, and could be easily compelled to abdicate for demonstrating dictatorial tendencies or incompetence. The order to vacate the throne was usually communicated through a symbolic message, or aroko, of parrots’ eggs delivered by the senators.
Before the abolition of the slave trade, some Yoruba groups were known among Europeans as Akú, a name derived from the first words of Yoruba greetings such as Ẹ kú àárọ? ‘good morning’ and Ẹ kú alẹ? ‘good evening’. The terms “Nago”, “Anago”, and “Ana”, derived from the name of a coastal Yoruba sub-group in the present-day Republic of Benin, were also widely used in Spanish and Portuguese documents to describe all speakers of the language. Yoruba in francophone West Africa are still sometimes known by this ethnonym today. In Cuba and Spanish-speaking America, the Yoruba were called “Lucumi”, after the phrase “O luku mi”, meaning “my friend” in some dialects. During the 19th century, the term Yariba or Yoruba came into wider use, first confined to the Ọyọ. The term is often believed to be derived from a Hausa ethnonym for the populous people to their south, but this has not been substantiated by historians. As an ethnic description, the word first appeared in a treatise written by the Songhai scholar Ahmed Baba (1500s) and is likely to derive from the indigenous ethnonyms Ọyọ (Oyo) or Yagba, two Yoruba-speaking groups along the northern borders of their terrority. However, it is likely that the ethnonym was popularized by Hausa usage and ethnography written in Arabic and Ajami. Under the influence of Bishop Samuel Ajayi Crowther, a Yoruba clergyman, subsequent missionaries extended the term to include all speakers of related dialects.
The pre-colonial Yoruba living in the savannah region between the forest and the Niger river were pressed further south by conflicts with the Sokoto Caliphate, a militant Muslim empire founded by the Fulani Quranic scholar Uthman Dan Fodio. After usurping power in the Hausa city-states of northern Nigeria, the Sokoto Caliphate also seized power in Ilorin, one of the northernmost Yoruba towns, and ravaged Ọyọ-Ile, the capital city of the Ọyọ Empire. After losing the northern portion of their region to the cavalry-dependent Sokoto Caliphate, the Ọyọ for the most part retreated to the latitudes where tsetse flies made horses unable to survive. The Caliphate attempted to expand further into the southern region of modern-day Nigeria, but was decisively defeated by the armies of Ibadan, a newly-founded Yoruba city, in 1840.