Fossil remains show that humanlike creatures lived in the area of Lake Rudolf perhaps two million years ago. As early as the third millennium BC , cattle were being herded in what is now northern Kenya. Sometime in the first millennium BC , food-producing Cushitic-speaking peoples, possibly from the Ethiopian highlands, appeared in Kenya. During the Iron Age (c. AD 1000), the first Bantu speakers arrived, probably from points south and west, resulting in the retreat of Cushitic speakers. The Nilotic speakers entered at the end of the 16th century from the north or northwest, from southern Sudan, and perhaps from the western Ethiopian borderland.
After their arrival, most groups settled into a pattern of slow and gradual movement highlighted by spurts of expansionist activity. For example, the Eastern Bantu (Kikuyu, Meru, Kamba, Pokomo, Teita, and Bajuni), possibly after settling in the area between Lamu and the Juba River, dispersed throughout southern and coastal Kenya. By 1400, the Kikuyu had reached the area near Mt. Kenya; they were joined there by the Meru in the 1750s. The Western Bantu (Luhya and Gusii) developed from an influx of Kalenjin (1598–1625) and Bantu (1598–1733) migrants. Other peoples, including the Luo, developed a strong ethnic identity and protected themselves from intruders. But as their population increased between 1750 and 1800, conflict arose, clans broke down, and another wave of migration ensued.
The Cushitic and Nilotic peoples (represented by Kalenjin ancestors of the Pokot, Nandi, Kipsigis, Kony, and Tugen) and others (such as the Turkana, Teso, and Galla) participated in independent movements beginning in the 16th century and lasting into the 18th. By 1800, the Kamba, acting as the chief carriers and go-betweens, dominated an extensive intergroup long-distance trade network that linked the interior to the East African coast. The last migrants into the country were the Somali, who did not enter northeastern Kenya in great numbers until the late 19th and early 20th centuries.
Meanwhile, another set of migrants settled on the Indian Ocean coast. As in the interior, the newcomers replaced the original hunter-gatherer inhabitants. In the period prior to the birth of Christ, Egyptians, Phoenicians, Persians, and possibly even Indonesians visited the coast. By the 10th century the Bantu had settled the coastal region in what the Arabs called the Land of the Zenj (blacks). As the area flourished, a mixed population of Arabs and Africans combined in creating the Swahili culture, a culture marked by its own language, a devotion to Islam, and the development of numerous coastal trade centers. Swahili cities such as Kilwa, Mombasa, and Pate remained independent of one another and of foreign control and, although they had little contact with the interior, grew wealthy from their mercantile contacts with India and Arabia.
Throughout the 16th century, following Vasco da Gama's landing at Malindi in 1498, the coastal cities struggled to remain independent of the external threats posed first by the Portuguese and then by the Omani Arabs. Although the Portuguese established posts and gained a monopoly of the trade along the Kenya coast, the Arabs eventually succeeded in driving out the Portuguese and reestablishing Arab authority in 1740. Independent Arab settlements persisted for a century until, during the rule (1806–56) of Sayyid Sa'id, a kind of unity was established. Arab control even in the 19th century continued to be confined to the coastal belt, however. In 1840, Sayyid Sa'id moved the capital of his sultanate to Zanzibar.
Europeans began to assert their influence in East Africa. After jostling with the Germans and the Italians for Zanzibari favors, the British emerged with a concession for the Kenya coast in 1887. European penetration of the interior had begun decades earlier with the explorations of two German missionaries, Johannes Rebmann and Johann Ludwig Krapf, in 1847–49, and by the English explorer John Hanning Speke at Lake Victoria in 1858. In 1886, the UK and Germany reached agreement on their respective spheres of influence in East Africa, and the Imperial British East African Company, a private concern, began establishing its authority in the interior two years later. In 1890, a definitive Anglo-German agreement was signed, and arrangements were made with the sultan of Zanzibar for
protection to be extended to his mainland holdings. When the company failed in 1895, the UK assumed direct control over the "East African Protectorate". In December 1901, the railway linking Mombasa with Lake Victoria was completed, and in the following year the boundary between Kenya and Uganda was shifted some 320 km (200 mi) westward to its present position. European and Asian settlement followed the building of the railway, and by World War I the modern development of Kenya was clearly evident. In 1920 the protectorate, with the exception of the coastal strip (later ceded by Zanzibar), was declared a crown colony.
In the interwar years, the major challenge to European political power came from Asians who wanted equality with Europeans in governmental representative institutions. This challenge was successfully resisted, but in the postwar period a more dynamic threat came from African nationalism.
Africans made use of both legal and nonlegal methods in their struggle for power with the Europeans. The first efforts ended in the eruption of the Mau Mau movement, and a state of emergency was declared in October 1952. Supported primarily by the Kikuyu, Embu, and Meru tribes of Central Province, Mau Mau was a secretive insurrectionary movement that rejected the European domination over Kenya. The emergency lasted until late 1959, and cost over UK £55 million. At one time, more than 79,000 Africans were detained, and about 13,000 civilians (almost all African) were killed.
During the initial period of the emergency in 1954, the "Lyttelton" multiracial constitution was imposed on Kenyan political groups unable to agree among themselves. It providing both for African and Asian participation in a council of ministers with Europeans and a system of communal representation for each racial group, with a formula of equality of representation in legislative and executive institutions between Europeans and non-Europeans. The introduction of direct elections for Africans to the Legislative Council in 1957 was their first outstanding political gain. With the 1960 "Macleod" constitution came an African-elected majority in the Legislative Council; this represented a decisive shift in the direction of an African-controlled state of Kenya. Rapid advancement toward self-government and independence under African leadership was delayed, however, because of conflicts between the two major African political parties over the future constitutional structure of the country. A constitutional conference in London in early 1962 produced a "framework" constitution, which included formation of a national government representing both political parties. Following new national elections under this constitution in May 1963, Kenya became self-governing on 1 June. On 12 December 1963, Kenya became independent. Exactly one year later it became a republic within the Common wealth of Nations, with Jomo Kenyatta as the country's first president. His political party, the Kenya African National Union (KANU), dominated the government, and leaders of a rival party, banned in 1969, were detained. On the other hand, some electoral choice was permitted: although all parliamentary candidates in 1969, 1974, and 1979 were KANU members, more than half the incumbents were unseated in the balloting.
An East African Community united Kenya, Tanzania, and Uganda in a common market and customs union until it was dissolved in 1977. Kenya has maintained remarkable political stability, despite territorial disputes with the Somali Democratic Republic, which resulted in sporadic fighting (1963-1968); and with Uganda (1970s). Tanzania closed its borders with Kenya between 1978 and 1983 because Kenya allegedly harbored Idi Amin's supporters after his fall.
Kenyatta died on 22 August 1978 and was succeeded by his vice president, Daniel Arap Moi, who was elected president without opposition a month later. In June 1982, the National Assembly voted unanimously to make Kenya formally a one-party state. On 1 August 1982, a group of junior air force officers, supported by university students and urban workers, attempted a military coup. Looting in Nairobi, particularly of Asian-owned stores, continued for days. This resulted in more than 500 people reported killed, dissolution of the entire 2,100-member air force, closing of Nairobi University, jailing of almost 1,000 persons, conviction and sentencing to death of 12 conspirators in the following months, and their reported execution in 1985. President Moi ran unopposed in the elections of September 1983; in the National Assembly voting during the same month, five cabinet ministers and 40% of all incumbents went down to defeat.
In 1986, Moi declared that KANU was above government, the parliament and the judiciary. Critics of Moi, even within KANU, were expelled from the party and government repression widened. Many opposition leaders were detained in July 1990 and in 1991 (including former vice president, Oginga Odinga), and clashes between pro-democracy demonstrators and police left five dead.
As pressures mounted for political reform, the United States and 11 other donor nations pressed Moi to reduce government corruption, to improve its poor human rights record, and to institute economic reforms. In 1991, these donors withheld more than $350 million in aid. In December 1991, Moi and his party legalized multiparty politics, but opposition to Moi and civil unrest continued. Ethnic violence from 1991 to 1994 in the Rift Valley left over 3,000 Kikuyu and Luo dead, allegedly the work of "trained warriors" from Moi's ethnic group. In 1993, Africa Watch, a US-based human rights group, reported that as many as 1,500 Kenyans have been killed and over 300,000 displaced as a result of ethnic violence instigated by Moi's regime in the Rift Valley. In the lead up to the 1997 general elections, ethnic fighting flared up in Mombassa, claiming over 42 lives. The death toll of these clashes pales in comparison to the Hutu-Tutsi genocide, but the social friction they have caused has provided Moi with what he terms "proof" that the country is too fractured along tribal lines to allow true multiparty democracy.
In Nairobi in January 1992, more than 100,000 attended the first legal antigovernment rally in 22 years. Through the years, the Forum for the Restoration of Democracy (FORD) had emerged as the main opposition. But a conflict between Kenneth Matiba and Odinga signaled ethnic divisions in the run-up to elections required by 21 March 1993. Moi, exploiting those weaknesses, delayed the elections until December. The opposition, divided into eight parties, saw its initial support fade away. Although the late December elections were generally peaceful, Matiba, Odinga, and Mwai Kibaki, of the Democratic Party of Kenya, refused to accept the results. Moi was reelected with 37% of the vote; Matiba had 26%, Kibaki 19%, and Odinga 17%. For the National Assembly, KANU won 100 of the 188 seats; FORD-Kenya, 31; FORD-Asili, 31; and DP, 23. However, many of Moi's cabinet ministers were defeated in their parliamentary contests.
Moi continued to demonstrate his authoritarianism in 1994 and 1995, as opposition groups struggled among themselves to present a united front. Moi's overtly heavy security apparatus stepped up internal oppression, leading the Kenyan Human Rights Commission to report that in the first nine months of 1995, security forces murdered 74 Kenyans in detention, 12 of whom were killed by torture. Violence conducted by unofficial Moi-supported gangs continued as well.
Despite this, opposition forces became vocal as the 1997 elections neared, demanding constitutional reform. Primary among the demands was a constitutional convention and at the very least parliamentary action limiting the powers of the president, and an electoral reform providing for a runoff election if no presidential candidate received more than 50% of the vote—a virtual certainty. Moi, elected with only 36% of the vote in 1992, publicly acknowledged the need for such reforms, but repeatedly postponed any action. This further inflamed opposition parties, and as protests grew more violent, Moi's repression followed suit. By September 9, 1997, over 70 people had been killed in demonstrations, including 7 protestors killed by police in July in a massive Nairobi demonstration that saw police beating religious leaders inside the Kenya Presbyterian Church at midday. Images of bloodied clerics fleeing armed mobs in the international media outlets led to harsher criticism, further marginalization, escalating civil unrest and violence. Moi refused to concede to opposition demands, insisting that democratic reforms would lead to the splintering of the country.
On 29 and 30 December 1997, Kenyans went to the polls without constitutional or electoral reform. Again, early hopes of a united opposition victory were dashed as divisions reemerged. Over nine parties split the opposition vote. Moi was reelected with 40% of the vote; Mwai Kibaki of the Democratic Party (DP) had 31%; National Democratic Party's (RDP) Raila Odinga had 11%; FORD-Kenya's M.K Wamalwa had 8%; and Charity Kaluki Ngilu of the Social Democratic Party (SDP) had about 8%. Of the 210 seats of the National Assembly, KANU won 108; DP, 39; NDP, 21; FORD-Kenya, 17; SDP, 15; Safina and three other parties shared 7 seats.
Following the 1997 elections, civil unrest continued, crime and corruption increased, while the AIDS pandemic claimed at least 600 lives per day. In February 2000 the British Foreign Office minister in charge of Africa, Mr. Peter Hain, referred to corruption in Kenya as "the economic equivalent of AIDS". Still, Moi managed to survive a vote of no confidence moved by opposition MPs in October 1998. After 30 months of snubbing the IMF, the Kenyan Government finally resumed formal relations with the IMF and in mid-January 2000, the IMF Board voted to resume aid to Kenya. The reestablishment of the East African Common Market was expected to increase trade among the three sister countries.
The opposition and civil society coalesced over the issue of constitutional reform. Bowing to mounting pressure and civil unrest, Moi finally consented to a Constitutional Review Commission Amendment Act, which became effective on 29 January 1999. However, squabbling over who should lead the review process delayed action into 2003. Limits on presidential powers and the establishment of a post for prime minister were among the constitutional issues expected to be addressed at a national constitutional convention sometime in 2003.
Following much speculation, Moi went on record saying he would retire at the end of his term in 2002. Although it appeared in April 2002 that elections would be postponed for a year to allow for the drafting of the constitution, the polls were held on 27 December 2002. Mwai Kibaki's landslide victory with 62.2% of the vote over Moi's hand-picked candidate Uhuru Kenyatta with 31.3% ended 24 years of KANU rule under Moi. In the parliamentary vote, Mbaki's National Rainbow Coalition (NARC) won 125 directly elected and seven appointed seats for a total of 132 seats compared to 64 directly elected and 4 appointed seats for KANU. Overall the polls were judged peaceful, free and fair.