After the Italian campaign, the Directory started pushing for an assault on England. Napoleon was against this, and with support from the Foreign Minister, Talleyrand, he convinced the Directory to back a less direct form of attack: an Egyptian campaign to threaten Britain's trade routes with its colony, India. Although Egypt was ostensibly a Turkish territory at the time, it was still under the control of the Egyptian Mamelukes, and thus the campaign was against these rulers' armies.
In 1798, Napoleon's forces managed to sail past Admiral Nelson and the British fleet to land in Egypt. Napoleon's forces immediately won decisive battles against the Mamelukes, including the Battle of the Pyramids. Before the battle, Napoleon demonstrated his flair for the dramatic: gesturing toward the nearby pyramids, he famously addressed his men, "Soldiers, forty centuries are watching you."
However, the Egyptian campaign did not consist solely of victories. Admiral Nelson, sore that the landing force had evaded his fleet, attacked the French fleet with a vengeance, decimating their ships at the Battle of Aboukir (Battle of the Nile) and leaving Napoleon's forces stranded in Egypt. However, Napoleon decided to try and take advantage of the situation to further assert his power, undertaking an attempt to modernize and westernize Egypt. But before his projects could get underway, Napoleon had word that the Turkish army was preparing to attack him in Egypt. In February of 1799, the French Army of Egypt moved north into Palestine and Syria to preempt the Turks, but encountered a tough siege at British-controlled Acre. By May, a decimated French Army limped back into Egypt.
Meanwhile, back in Europe, war was breaking out. The Russian army was making conquests as far west as Switzerland, and the "Cisalpine Republic" established by the Italian campaign had crumbled. France was in chaos, and Napoleon decided to abandon his position in Egypt to pursue his career in France, in hopes of overthrowing the Directory, which he now referred to as "that bunch of lawyers." Somehow, Napoleon again managed to sneak past Nelson's blockade, and made a surprise appearance in Paris. On November 9, 1799, along with Talleyrand and the revolutionary Father Sieyes, Napoleon achieved a coup d'etat against that Directory. The new government of the Republic was to be called the "Consulate," as it was ruled by three consuls, of which Napoleon was to be "First Consul."
Why was Napoleon against the cross-channel assault on England? He argued that it would be doomed to failure so long as Britain had Europe's dominant Navy. Rather than engage in direct battle, he preferred to weaken Britain first, debilitating it economically by cutting off its trade route to India. Napoleon may also have suggested the Egyptian campaign out of concern for his own reputation and career: he knew he would have a better chance of winning that battle than of conquering England. Meanwhile, the Directory, fearing Napoleon's political ambitions and growing popularity, gladly agreed to a measure that would take him so far from Paris.
Napoleon's problems in Egypt and the defeat of the French fleet at Aboukir were the first signals that Napoleon could be beaten. Encouraged by these, a new coalition of Russia, England, Austria, and Turkey sprang up against France.