After decades of stability, Côte d'Ivoire's troubles began in September 2002, when troops from the north gained control of much of the country. A truce was short-lived and fighting resumed, this time also over prime cocoa-growing areas. France sent in troops to maintain the ceasefire boundaries; meanwhile, Liberian tensions from that country's war began to spill over the border, which escalated the crisis in parts of western Côte d'Ivoire and foreshadowed future events.
In January 2003, President Laurent Gbagbo and the leaders of the New Forces, a newly formed coalition of rebel groups, signed accords creating a 'government of national unity', with representatives of the rebels taking up places in a new cabinet. Curfews were lifted and French troops cleaned up the lawless western border, but the harmony was short-lived.
In March 2004 a peace deal was signed, and Guillaume Soro, formerly the secretary of the New Forces rebel coalition, was named prime minister. UN peacekeepers arrived, but on 4 November Gbagbo broke the ceasefire and bombed rebel strongholds, including Bouaké. Two days later, jets struck a French military base, killing nine French peacekeepers. In retaliation, the French destroyed much of the Ivoirian air force's fleet. Government soldiers clashed with peacekeepers, while most French citizens fled, and dozens of Ivoirians died.
Amid reports that Gbagbo was rebuilding his air force, a UN resolution backed his bid to stay in office until fair elections could be held. In April 2007 French peacekeepers began a staged pullback from the military buffer zone, to be replaced gradually by mixed brigades of government and rebel troops. Gbagbo declared the end of the war and the two sides moved to dismantle the military buffer zone.
In June that year a rocket attack on Prime Minister Soro's plane killed four of his aides, shaking the peace process further. Protests over rising food costs spread through the country in April 2008, causing Gbagbo to put the elections back to November. A month later, northern rebels began the long disarmament process. Just days before the planned elections, the government postponed them yet again, amid disorganised voter registration and uncertainty about the validity of identity cards. The elections were finally held in 2010.