By 1799, the French Revolutionary Wars had resumed after a period of relative peace in 1798. The Second Coalition had organized against France, with Great Britain allying with Russia, Austria, the Ottoman Empire, and several of the German and Italian states. While Napoleon's army was still embroiled in Egypt, the allies prepared campaigns in Italy, Switzerland, and the Netherlands.
Napoleon had consolidated his control of Egypt for the time being. Soon after the beginning of the year, he mounted an invasion of Syria, capturing El Arish and Jaffa. On 17 March, he laid siege to Acre, and defeated an Ottoman effort to relieve the city at the Battle of Mount Tabor on 17 April. However, his repeated assaults on Acre were driven back by Ottoman and British forces under the command of Jezzar Pasha and Sir Sidney Smith. By May, with plague rampant in his army and no sign of success against the city, Napoleon was forced to retreat into Egypt.
In July, Turkey, with the help of the British navy, mounted an invasion by sea from Rhodes. Napoleon attacked the Turkish beachheads and annihilated their army at Aboukir.
In August, Napoleon decided to return to Europe, hearing of the political and military crisis in France. Leaving his army behind with Kléber in command, he sailed through the British blockade to return to Paris and resolved to take control of the government there in a coup.
In August, the allies mounted an invasion of the Netherlands (which at that time was a French vassal state, the Batavian Republic) with a combined Anglo-Russian army under the Duke of York, who landed at the northern tip of Holland. This army fought a series of battles ending in the defeat at Castricum on 6 October. That town passed from British-Russian to Batavian-French hands several times until the former finally fled, losing 2536 men and 11 guns; the Batavian-French losses stood at 1382.
The Battle of Castricum persuaded the Duke that his position was untenable. After a chaotic retreat, in which two field hospitals were "forgotten", he reached an agreement with the French commander, Brune. The British and Russians were allowed to withdraw, without paying reparations, and retaining captured bounty. As thanks, Brune received a number of magnificent horses from the Duke. By 19 November all the British and Russian troops had been embarked and the whole unhappy episode was over.
By January, the French army had pursued the Neapolitan army from Rome to Naples, taking the capital. French general Schérer attacked the Austrian army under Kray, but was heavily defeated at Magnano near Verona on 5 April. Russian general Suvorov, taking over the allied campaign, pursued the French to Cassano, defeating them and recapturing Milan and Turin. In June, Suvorov won the Battle of Trebbia against a reinforcing army under MacDonald, pushing the French back into the Alps and Genoa. Gen. Moreau was briefly appointed to command the French forces, followed quickly by General Joubert, who was severely defeated at Novi, a few miles south of Marengo. Joubert was killed there amongst the French skirmishers while reconnoitering the enemy lines. By the end of the year, French forces had almost been driven from Italy and Suvorov was ordered to Switzerland.
The French offensive relied on coordinated attacks by the Army of the Danube, the Army of Mayence, and the Army of the North.
On 1 March 1799, the Army of Observation, in an order of battle of approximately 30,000 men in four divisions, crossed the Rhine at Kehl and Basel. The following day, the it was renamed the Army of the Danube.
Under command of Jourdan, the army advanced in four columns through the Black Forest. First Division, the right wing, assembled at Hüningen, crossed at Basel and advanced eastward along the north shore of the Rhine toward Lake Constance. The Advanced Guard crossed at Kehl, and Vandamme led it north-east through the mountains via Freudenstadt. This column eventually became the left flank. It was followed across the Rhine, also at Kehl, by the II. Division. The Third Division and the Reserve also crossed at Kehl, and then divided into two columns, III. Division traveling through the Black Forest via Oberkirch, and the Reserve, with most of the artillery and horse, by the valley at Freiburg im Breisgau, where they would find more forage, and then over the mountains past the Titisee to Löffingen and Hüfingen.
The major part of the imperial army, under command of the Archduke Charles', had wintered immediately east of the Lech, which Jourdan knew, because he had sent agents into Germany with instructions to identify the location and strength of his enemy. This was less than 64 kilometres (40 mi) distant; any passage over the Lech was facilitated by available bridges, both of permanent construction and temporary pontoons and a traverse through friendly territory.
In March 1799, the Army of the Danube engaged in two major battles, both in the southwestern German theater. At the intensely fought Battle of Ostrach, 21–2 March 1799, the first battle of the War of the Second Coalition, Austrian forces, under the command of Archduke Charles, defeated Jourdan's Army of the Danube. The French suffered significant losses and were forced to retreat from the region, taking up new positions to the west at Messkirch (Mößkirch, Meßkirch), and then at Stockach and Engen. At the second battle, in Stockach, on 25 March 1799, the Austrian army achieved a decisive victory over the French forces, and again pushed the French army west. Jourdan instructed his generals to take up positions in the Black Forest, and he himself established a base at Hornberg. From there, General Jourdan relegated command of the army to his chief of staff, Jean Augustin Ernouf, and traveled to Paris to ask for more and better troops and, ultimately, to request a medical leave.
The Army was reorganized, and a portion placed under the command of André Masséna and merged with the Army of Helvetia. Following the reorganization and change in command, the Army participated in several skirmishes and actions on the eastern part of the Swiss Plateau, including the Battle of Winterthur. After this action, three forces of the imperial army united north of Zürich, completing a partial encirclement of Masséna's combined Army of the Danube and Army of Switzerland. A few days later, at the First Battle of Zurich, Masséna was forced west, across the Limmat. In late summer, 1799, Charles was ordered to support imperial activities in the middle Rhineland; he withdrew north across the Rhine, and marched toward Mannheim, leaving Zürich and northern Switzerland in the hands of the inexperienced Alexander Korsakov and 25,000 Russian troops. Although the highly capable Friedrich Freiherr von Hotze remained in support, his 15,000 men were not able to counter Korsakov's poor defensive arrangements. Three weeks later, at the Second Battle of Zurich, the Russian force was annihilated, and Hotze was killed south of Zürich. This left Masséna in control of northern Switzerland, and closed forced Suvorov into an arduous three week march into the Vorarlberg, where his troops arrived, starving and exhausted, in mid-October.
In March, Masséna's army occupied Switzerland, preparing an attack against Tyrol through Vorarlberg. However, the defeats of French armies in Germany and Italy forced him to return to the defensive. Taking over Jourdan's army, he pulled it back into Switzerland to Zürich. Archduke Charles pursued him and drove him back at the First Battle of Zurich. When Charles left Switzerland for the Netherlands, the allies were left with a smaller army under Korsakov, who was ordered to unite with Suvorov's army from Italy. Masséna attacked Korsakov, crushing him at the Second Battle of Zurich, and forcing Suvorov to retreat with considerable loss. Russia abandoned the Second Coalition soon after this debacle.