The Egyptians switched from a hunter-gatherer race to settled agriculturalists around 5,500 BC, and even at this early stage their distinctive custom of burying the dead away from centres of population with provisions and offerings to help their journey to the afterlife is apparent from excavations. In many museums you'll find pottery and other items labelled Naqada, which date from this time.
Egypt can trace its dynastic history back to around 3,000 BC, when Upper and Lower Egypt were unified under an Egyptian king called Menes. Thus began two and half thousand years of Pharaonic times that saw the building of Egypt's finest monuments, from the Step Pyramid at Saqqara, via the Pyramids and Sphinx at Giza (now a suburb of Cairo), the tombs of the Valley of the Kings and the twin temples of Abu Simbel to the Ptolemaic temples at Philae and Dendara.
The ancient Egyptian civilisation, arguably the greatest the world has ever seen, left an incomparable legacy - no other country can boast such an awesome array of temples and tombs, statues and artefacts. The Romans used to visit the country as tourists (and were happy to remove objects to decorate their own monuments back at home.
During his campaigns in Egypt, Napoleon was astounded by her treasures and set up the first main project aimed at describing the monuments (the Description d'Egypte), while it was a Frenchman, Jean-François Champollion, who used the celebrated trilingual Rosetta Stone (now in the British Museum) to break the code which allowed subsequent generations to read and understand the Egyptian hieroglyphic writing.
The British have also been entranced by the country since the early 19th century, and, not surprisingly, the world is still gripped by Egyptomania.
Getting to grips with the country's ancient history, however, will take more than one visit; indeed, historians and archaeologists are still arguing over what happened when anyway. But you don't need a degree in ancient history to enjoy what this marvellous country has to offer (just don't believe everything your local guide will tell you as you wander around the main sites).
Pharaonic times date from around 3,000-341 BC. We all learned about the all-powerful pharoahs at school, and who doesn't know the name of Tutankhamen, the boy king whose tomb was the only one - so far - to have been discovered still with most of its treasures.
Rameses II, possibly the pharoah of the times of Moses, is another name you should know, for he built Abu Simbel, and made his mark with a number of immense statues of himself at Luxor and Karnak temples in what was Ancient Thebes.
Dynastic Egypt has been split into several well-defined eras: the Old, Middle, New and Late Kingdoms, although some debate still surrounds what precisely happened in the periods in between - known as the First, Second and Third Intermediate periods - when anarchy appeared to take over and the pharaohs lost control of the country, which was itself split into two regions, Upper and Lower Egypt.
The first pyramid, the Step Pyramid at Saqqara, was built in around 2,650BC by King Zoser. The Pyramids at Giza date from the 4th Dynasty, about 2,550 BC; the tomb of Tutankhamun from 1323BC. It wasn't until 332 BC that Alexander and the Greeks arrived to take control from the ancient Egyptians, and there were an awful lot of pharoahs in between.
Egypt had already been invaded by the Libyans, Ethiopians, Persians and Assyrians when Alexander arrived, founding a city named after him in the north. After his death, a series of Macedonian generals called the Ptolemies ruled, and a great period of Greek influence followed. The temples at Dendara, Philae and Edfu are not ancient Egyptian, but built by the Greeks to appease the population, and represent a melding of the ancient Egyptian and Greek religions.
As the Roman Empire expanded, the Ptolemies were left to rule Egypt unhindered, until the rule of Cleopatra - a Greek, not an Egyptian - who famously seduced and set up an alliance with Mark Antony. When a would-be Roman emperor (Octavian, who later became Augustus) was sent to sort them out, both committed suicide and Egypt became a Roman province in 30BC, which it remained for 300 years.
As the Roman Empire collapsed, Nubians from the south and North Africans invaded. At the same time, the Coptic, or Christian, church thrived in Egypt: the first Christian monks were hermits who settled, at first alone and then in communities in the western desert. You'll often find crosses and other Christian symbols gouged into the walls of older temples as a sign of their disgust at the 'decadent' former beliefs.
In 642, Arabs conquered the country, bringing Islam to the Egyptians. Assorted Arabian rulers and later Turkish mercenaries called Mameluks took control until 1517 when the Turks invaded. They held power until 1798 when Napoleon arrived, who himself was ousted by the British in 1802.
Several Egyptian groups vehemently opposed to European domination of the country were formed, but it wasn't until 1952 that the Free Officers, led by Colonel Gamal Abdel Nasser, overthrew King Farouk in a bloodless coup and the first independent Arab Republic of Egypt was formed.
In 1956, Nasser nationalised the Suez Canal, and the British and French, anxious to retain some control over this important waterway, secretly agreed to co-operate with the Israelis, who launched an attack and British paratroops went in. The US and the Soviet condemned the action and a UN peacekeeping force was installed to remedy the situation.
Egypt's continuing conflict with Israel led to a number of actions, including the Six Day War of 1967, and the October War of 1973. President Sadat, later assassinated, signed a peace treaty with Israel in 1979.
The current president, Hosni Mubarak, came to power in 1981. He has clamped down heavily on Islamic fundamentalist groups who were behind a number of terrorist attacks on tourists in the mid-1990s, and has battled to improve the country's economy.
Today's visitors to Egypt will see a land of contrasting faces. The prosperous, westernised cities of Cairo and Alexandria in the north; the poorer, traditional lifestyles of farmers in the south; purpose-built resorts at the Red Sea; bustling tourist centres at Luxor and Aswan; and bleak sand and mountain desert in between.
Ancient temples rub shoulders with exotic mosques from which muezzins call the Moslem faithful to prayer; Coptic churches sit beside modern skyscraper hotels. And flowing past, just like it did 5,000 years ago, is the timeless river Nile.