Egypt's modern history is widely considered to begin in 1798, when NapoleonBonaparte showed up with a large army as part of the [[NapoleonicWars French Revolutionary Wars]]. Egypt had at this point spent 350 years as a province of TheOttomanEmpire, ruled in a complicated arrangement with elements dating back to TheCrusades: though the Sultan in Constantinople appointed a governor, he had to share power with the Mamelukes, warrior-slaves (it's complicated) who had ruled the country after a palace revolt ousted the Ayyubid dynasty founded by Saladin. As one might imagine, history had largely passed Egypt by, particularly after Europe's mastery of ocean travel allowed them to cut out the (Egyptian) middleman in the lucrative trade in Far Eastern spices. So when Napoleon comes in with a modern army, modern laws, and a ''printing press'', you can rather understand the shock to Egyptian society--and indeed, the whole of the Ottoman Empire.

The French were eventually forced to withdraw by a coalition of British and Ottoman forces (although not before a team of 167 French scientists had a chance to produce a massive ''Description de l'Egypte'' and discover and run away with the Rosetta Stone) in 1801. However, in 1805, an Albanian officer in the Ottoman Army named Muhammad Ali (no, not the former Cassius Clay), resorting to some bloody tactics (e.g. slaughtering all the Mamelukes on their way to a banquet) became governor. Based on what the French had done, Muhammad Ali began modernizing Egypt, creating a European-style bureaucracy, establishing a military on Western lines (called the Nizam al-Gadid, or "New Order," a term later adopted by the central Ottoman government for its similar plan), building a navy, constructing arsenals for the manufacture of modern weapons, building schools, and adopting a new cash crop--cotton--for Egyptian farmers to raise and sell to Europe, and particularly Britain, whose cotton-hungry textile mills were leading the IndustrialRevolution. From this point on, Egypt was more or less independent of the Sultan--just how independent changed over time--and seemed on its way to becoming Japan about fifty years before Japan.

However, Muhammad Ali was also something of a traditionalist, regarding Egypt as his own personal domain--or rather, his family's--and was more or less a traditional Middle Eastern despot. This included a desire for conquest, and he eventually led a campaign against the Sultan which, while initially successful (capturing most of UsefulNotes/{{Sudan}}, Syria[[note]]Which at the time consisted of what is now UsefulNotes/{{Israel}}[=/=]UsefulNotes/{{Palestine}}, UsefulNotes/{{Jordan}}, and UsefulNotes/{{Lebanon}}, as well as modern UsefulNotes/{{Syria}}[[/note]] and the Hejaz--where Mecca and Medina are--for himself), the Sultan decided to [[SummonBiggerFish call in the assistance of the British]], who promptly crushed him in 1840, losing Syria and the Hejaz, but keeping Sudan. As a consolation prize, however, his rule over Egypt was made hereditary, with the title of Pasha (roughly equivalent to "Duke"). In 1848 he died, passing power to his grandson Abbas.

This ushered in the first quasi-independent Egyptian dynasty in centuries, the Muhammad Ali dynasty. Over time, Egypt was two steps forward, one step back as far as its independence from Constantinople was concerned, with the European powers constantly trying to meddle in the country's domestic affairs. Unfortunately for Egypt, the rulers after Muhammad Ali had neither his modernizing spirit (as limited as it was) nor his military prowess nor his political skills, and quickly fell prey to the schemes of the Europeans, of which the most significant was the Suez Canal.

Abbas' successor, Sa'id, granted the French engineer Ferdinand de Lesseps the right to design and build the canal. This in itself was not particularly troubling--the canal on its own would probably bring at least ''some'' wealth to Egypt--but it started a chain of events that ultimately led to some really nasty times for Egypt. You see, de Lesseps had counted on being able to sell shares in the project on the market in Europe, but [[ItWillNeverCatchOn nobody thought it realistic or profitable]]. As a result, de Lesseps turned to Egypt itself; Sa'id agreed to finance the project to the tune of 3,000,000 pounds sterling, which was money Egypt didn't have. As a result of this and a costly war with UsefulNotes/{{Ethiopia}}, Egypt took a number of loans from the major European powers, giving them the leverage necessary to extract highly unpopular concessions out of Egypt (by this time ruled by Sa'id's nephew Ismail, who had taken the title ''Khedive''--"grand duke" or "ruling prince," more or less). Combined with really ''dumb'' financial management, the national debt skyrocketed from three million pounds to ''one hundred million'' (truly astronomical numbers in the 1870s). Eventually, in 1878, the European powers forced Ismail to become a constitutional figurehead monarch, with an Egyptian prime minister and an Englishman as Minister of Finance--the idea being to get Egypt's debts in line.

However, this arrangement was unpopular enough that in 1879, the Egyptian people revolted. Led by the disaffected colonel Ahmed Orabi, they managed to keep things going for three years, but in 1882, [[BritsWithBattleships British troops]] arrived to take control of the country. Egypt, while still nominally a part of the Ottoman Empire, was now a protectorate under British military occupation; maps of the day include Egypt as part of TheBritishEmpire.

Egypt managed to continue to develop under British rule, but the first three decades were restless. During UsefulNotes/WorldWarI, the Khedive Abbas II declared his support for the Ottomans, who (as luck would have it) were on the opposite side of the war from Britain. Britain quickly moved to depose Abbas and declare Egypt an independent Sultanate, with his more pliable uncle Hussein Kamel as Sultan. Hussein Kamel died in 1917; his brother Fuad took his place.

After the armistice of November 1918, the Paris PeaceConference was called, and like many colonized peoples, the Egyptians wanted the opportunity to speak their piece. One man, Saad Zaghloul, formed a delegation ("Wafd" in Arabic) to present their case (for some kind of constitutional monarchy, just like Britain) to the British Resident-General (i.e. colonial governor in all but name); they were also refused the opportunity to ask London. Instead, the ''Wafd'' ended up putting pressure on the official Egyptian delegation to Paris, which, being hand-picked by the British, came back essentially empty-handed.

This rather quickly led to another revolution, led by Zaghloul and his ''Wafd'' (by now the Wafd Party). Unlike the Orabi Revolt, it was chiefly a nonviolent movement, consisting of demonstrations, marches, and sit-ins. Zaghloul quickly became a national hero; the traditionally-elitist Egyptian nationalist movement spread to all parts of society. The protest movement was eventually broken up by British military action, resulting in about 4,000 Egyptian deaths and many more wounded.

However, the revolt forced Britain's hand; Egypt was declared a sovereign kingdom--with Fouad as King--in a unilateral declaration of independence signed by the British sovereign in 1922. That's right. ''Britain'' declared Egypt independent. Naturally, many Egyptians were confused, but the reality was that it was all a plot to change things on the surface without actually doing anything at all. While the new Kingdom of Egypt was nominally a constitutional parliamentary monarchy--just like Britain!--the fact was that British troops remained in the country, and the Egyptian Foreign Ministry took its marching orders from {{Whitehall}}. The British Ambassador wielded just about as much power as the Resident-General had before.

Nevertheless, Egypt managed to grow up quite nicely under this arrangement, although corruption, illiteracy, and other problems plagued the country. As time went on, one of the most obvious problems came to the fore: though Egypt was an agrarian country, the vast majority of its land was owned by a very small number of aristocrats, who rented out their land to the peasants in a quasi-feudal system (indeed, the Arabic word for this system--''iqta`iyyah''--is the same one applied to the kind of feudalism that existed in medieval Europe). Both the middle class and social mobility were virtually nonexistent. As a result, you had a tiny and absurdly rich upper class, highly Westernized, ruling over a mass of impoverished peasants. The gap became even more obvious under King Farouk, who acceded to the throne at the age of 16 in 1936. Something of a RoyalBrat, Farouk was a notorious [[AdiposeRex glutton]], [[TheCasanova womanizer]], gambler, and [[TheAlcoholic drunk]], to say nothing of a literal [[StickyFingers kleptomaniac]] who once filched UsefulNotes/WinstonChurchill's watch and on another occasion stole a sword belonging to the Shah of UsefulNotes/{{Iran}} (his brother-in-law). Things got to the point where even the BellyDancer hired to entertain at one of his parties took the opportunity to chew him out ("Your place is in the palace, helping govern the country, not at the casino!"). ("King Farouk" became something of a byword for "living in extreme luxury among really poor people"; for instance, HunterSThompson used it in ''FearAndLoathingInLasVegas'').

In any case, one of the few ways in which a peasant could better his status in society was through the military. Starting in the mid-19th century, a young peasant could even become an officer if he was sponsored by a member of the nobility (this was how Orabi had become a colonel in the first place); in the early 1940s, even this requirement was lifted. This proved to be a very bad move for the Egyptian monarchy.

One of the first officers to enter the Egyptian military academy without noble sponsorship was a fellow by the name of UsefulNotes/GamalAbdelNasser. Nasser, from the southern "Upper" part of Egypt, was something of an intellectual (for a military type), and had read works on socialism and the relatively new movement of Arab nationalism before and during his time at the academy. With a few like-minded members of his academy class, Nasser formed the Free Officers' Movement after the debacle that was the [[ArabIsraeliConflict 1948 Arab-Israeli War]]. On 23 July 1952, the Free Officers' Movement moved against the king, deposing him and (for the time being) installing his infant son Fuad II as monarch, with a Regency Council established, composed of several of the Free Officers.

Eventually, however, the officers decided that enough was enough. The Republic of Egypt was declared on 25 July 1953. Three days later, General Mohamed Naguib--the highest-ranking of the Free Officers--became the first President of Egypt, and the first native Egyptian to rule Egypt in over 3,000 years. The Regency Council became the Revolutionary Command Council.

However, Naguib was also the most conservative man in the group, seeing the military's role as one of cleaning out the corrupt regime and then returning to the barracks. Nasser and most of the RCC disagreed, believing that the revolution (a coup, really) still had work to do, and (more to the point) scared (not without basis) that the same liberal landlords who led the Wafd would win in any free democratic election. No, they concluded, there was too much drastic reform needed in the country, which (they said) was best done by the military. This included several public-works project and land reform. This bit of history is really only interesting to Egyptians and economists, so we'll leave it out, except to say that Naguib was forced out and replaced by Nasser in 1954.

However, in 1956, one of these public-works projects--the Aswan High Dam--ran into an issue: the United States' conditions for funding it were unacceptable to Nasser and his government. (At the time, Egypt was backed by both the US and the USSR, against Britain and France). As a consequence, Nasser declared the nationalization of the Suez Canal--the profits from which would hopefully pay for the construction of the dam, and provide a good bargaining chip against the Americans if it didn't--and ordered the British troops (who were still there despite all this tumult) to leave. Consequently, Britain and France came up with ASimplePlan: Israel would attack the Sinai, and then Britain and France would take the Suez Canal to "separate" Egypt and Israel "in the interest of peace." The conspiracy was so transparent that Nasser was able, through clever diplomacy, to get the US and Soviet Union to support a UsefulNotes/UnitedNations Security Council resolution condemning the three of them (Britain, France, and Israel), and eventually getting them to leave.

This made Nasser a hero, not just in Egypt, but in the whole Arab world. This led to a short-lived union with UsefulNotes/{{Syria}}--the cradle of Arab nationalism--from 1958 to 1961, known as the United Arab Republic. Although Syria would leave the union following a coup--mostly thanks to Nasser's hamhanded handling of the constitutional arrangements of the country--Egypt would retain the name "United Arab Republic" until 1971.

Most of Egypt's interesting history from 1961 to 1971 is already covered in ArabIsraeliConflict, so...

In any case, in 1970 Nasser dies at 52, leaving his Vice President, Anwar Sadat, in charge of the country. Sadat does some interesting things--like [[ThePurge purging the government of his enemies]] and [[ThePlan planning his way]] into a relatively dignified peace with Israel after the war of '73 ends up as merely a defeat rather than a disaster--before biting an assassin's bullet in 1981.

Now, Sadat did three things that are important to the rest of Egypt's story. The first is to declare the Arab Republic of Egypt--the current incarnation of the Egyptian state--with a nominally democratic, pluralistic, semi-presidential system. In actual fact, the National Democratic Party founded by Sadat won every election, by means both fair and foul. The second was to take Egypt's economy--which had been quasi-socialist under Nasser--and start privatizing it by bits and pieces, and opening it up to foreign investment. The third was appointing an Air Force general named Hosni Mubarak his vice president.

Now, a word about Hosni Mubarak. The Egyptian people are notoriously fond of jokes--the [[NationalStereotypes stereotype]] of Egyptians among the other Arabic-speaking peoples is that they are, in effect, {{Boisterous Bruiser}}s with a quick and sharp if rather crude sense of humor. One of the best ways to learn about Egyptians' opinions of their leaders is to listen to their jokes about said leaders. Jokes about Nasser tended to be good-natured fun-poking at minor quibbles in his personality, as well as less-good-natured jokes about the excessive [[PoliceBrutality brutality]] of his SecretPolice. Jokes about Sadat tended to portray him as a [[MagnificentBastard charismatic and cunning]] [[{{Hypocrite}} two-faced hypocrite/flip-flopper]]. Jokes about Mubarak consistently portray him as an [[TheDitz abject idiot]]. Seriously. One famous joke from the '90s implies that he is a donkey in human form. Another one says that the reason he never appointed a vice president was that he literally couldn't find anyone in Egypt stupider than him. One Egyptian-American journalist compares him to UsefulNotes/DanQuayle. Unfavorably. You can see where this is going.

In any case, Mubarak took Sadat's economic policy UpToEleven. Fully embracing the Washington Consensus before it was cool, Mubarak opened the floodgates of foreign investment and privatization--but at a cost. Most of this privatization was done as sweetheart deals to cronies, and much of the foreign investment eventually proved to be so many numbers games. As a result, after the initial effects of this economic opening (chiefly the consequence of millions of Egyptians going to work in the oil industry in the Persian Gulf states, making a quick buck there, and starting businesses back home), Egypt's economy started to sag again, and although there was now a very large middle class, the gap between ''that'' and the rich began to widen.

In the meantime, Mubarak remained unchanged. He ruled with a [[BoringButPractical steady, uninspiring, and rather heavy hand]]. Or should we say ''extremely'' heavy hand, given that the Egyptian SecretPolice--the State Security Investigations Service (SSIS)--eventually proved to have a good 1-2% of the population on its payroll, and was so noted for its skill at ColdBloodedTorture that Egypt became the destination of choice for [[http://en.wikipedia.org/wiki/Extraordinary_rendition extraordinary rendition]]. As economic problems began to mount and the notoriety of the SSIS began to grow, a new element was thrown into the mix--the likelihood that Mubarak would hand-pick his younger son Gamal to succeed him as President.

This was quite enough for most Egyptians, and when rumors began to spread around 2005, a protest movement--called ''Kefaya'' ("Enough" in Egyptian Arabic)--demanded that this not happen (and that some other things happen). This didn't go anywhere at the time, but then...

On 14 January 2011, the UsefulNotes/{{Tunisia}}n people successfully overthrew ''their'' ruler of 20-odd years, Zine El-Abedine Ben Ali. A bunch of Egyptians were like, "[[FollowTheLeader hey, if they can do that, why not us]]?" So they posted an event on {{Facebook}} that said "25 January: Egyptian Revolution" (or words to that effect). [[ItWillNeverCatchOn Most everyone laughed it off]].

These people were wrong. Very wrong.

Long story short, the 25 January protest movement became a full-fledged revolution. Mubarak departed on 11 February, leaving power to the Supreme Council of the Armed Forces (essentially, the Egyptian General Staff). [[http://en.wikipedia.org/wiki/Egyptian_parliamentary_election,_2011 Parliamentary elections]] were held in late 2011 and early 2012. The Muslim Brotherhood's Freedom and Justice Party won 235 seats with its allies (out of 498 elected seats and 10 appointed seats), followed by the Salafist[[note]]Aptly described by at least one Western journalist as "[[HolierThanThou more-Islamist-than-thou]]"[[/note]] Al-Nour Party[[note]]Literally, "The Light Party"[[/note]], which won 123 seats, again with its allies. [[http://www.bbc.co.uk/news/world-middle-east-18439530 The parliament was dissolved by court order on June 14th.]]

In short, Mubarak just became an Egyptian [[UsefulNotes/{{Indonesia}} Suharto]].

[[http://en.wikipedia.org/wiki/Egyptian_presidential_election,_2012 Presidential elections]] were held in 2012, under a two-round system. The first round, which took place on May 23 and 24, resulted in the FJP's Mohamed Morsi facing off against Ahmed Shafik, Mubarak's last Prime Minister- a choice widely seen as a MortonsFork by many people. The second round was held on June 16 and 17. The results were supposed to be announced on the 21st, but were delayed to the 24th. The final results had Morsi taking 13,230,131 votes (51.73%) against Shafik's 12,347,380 (48.27%). Further complicating things was the fact that the SCAF [[http://www.aljazeera.com/indepth/spotlight/egypt/2012/06/201261812449990250.html took several powers]] for itself a day after the election, stripping much power away from the President. A few months later, Morsi [[KickedUpstairs retired the whole SCAF, gave them big fat pensions, and showered them with medals and decorations]]. The SCAF was taken utterly by surprise and acquiesced. (They probably realized that [[XanatosGambit they couldn't win]]: Morsi couldn't have done this without the support of some junior officers, and refusal of retirement would be tantamount to a highly-unpopular coup.) Since then, political attention has turned primarily towards new parliamentary elections (date as yet TBD) and the constitutional assembly (everything about it TBD). There was a flap/large angry protests about a particularly vitriolic anti-Muslim film (which proved to have been made by a Copt living in America) and general dislike of meddling foreign powers (especially America) in mid-September 2012, but the main focus in Egypt itself remains on the future.