Bernadotte, considerably piqued, thereupon returned to Paris, where the council of ministers entrusted him with the defence of the Netherlands against the British expedition in Walcheren. In 1810, he was about to enter upon his new post as governor of Rome when he was unexpectedly elected the heir to King Charles XIII of Sweden, partly because a large part of the Swedish Army, in view of future complications with Russia, were in favour of electing a soldier, and partly because Bernadotte was also very popular in Sweden, owing to the kindness he had shown to the Swedish prisoners during the recent war with Denmark. The matter was decided by one of the Swedish courtiers, Baron Karl Otto Mörner, who, entirely on his own initiative, offered the succession to the Swedish crown to Bernadotte. Bernadotte communicated Mörner's offer to Napoleon, who treated the whole affair as an absurdity. Bernadotte thereupon informed Mörner that he would not refuse the honor if he were duly elected. Although the Swedish government, amazed at Mörner's effrontery, at once placed him under arrest on his return to Sweden, the candidature of Bernadotte gradually gained favor there, and, on 21 August 1810, he was elected the Crown Prince and made the Generalissimus of the Swedish Armed Forces.
On 2 November Bernadotte made his solemn entry into Stockholm, and on 5 November he received the homage of the Riksdag of the Estates, and he was adopted by King Charles XIII under the name of "Charles John" (Karl Johan). The new Crown Prince was very soon the most popular and most powerful man in Sweden. The infirmity of the old King and the dissensions in the Privy Council of Sweden placed the government, and especially the control of foreign affairs, entirely in his hands. The keynote of his whole policy was the acquisition of Norway and Bernadotte proved anything but a puppet of France. In 1813, he allied Sweden with Napoleon's enemies, Great Britain and Prussia, of the Sixth Coalition, in order to secure this. After the defeats at Lützen (2 May 1813) and Bautzen (21 May 1813), it was the Swedish Crown Prince who put fresh fighting spirit into the Allies; and at the conference of Trachenberg he drew up the general plan for the campaign which began after the expiration of the Truce of Plaswitz. Charles John, as the Commander-in-Chief of the Northern Army, successfully defended the approaches to Berlin against Oudinot in August and against Ney in September at the Battles of Grossbeeren and Dennewitz; but after the Battle of Leipzig he went his own way, determined at all hazards to cripple Denmark and to secure Norway.
As the union King, Charles XIV John, who succeeded to that title in 1818 following the death of Charles XIII, was initially popular in both countries. Upon his accession he converted from Roman Catholicism to the Lutheranism of the Swedish court. He would never learn to speak Swedish or Norwegian, though this did not pose a serious obstacle to his rule, since French was widely spoken by all of the aristocracy of the time.
Charles XIV John's reign witnessed the completion of the southern Göta Canal, begun 22 years earlier, to link Lake Vänern to the sea at Söderköping 180 miles to the east. Though his ultra-conservative views were unpopular, particularly from 1823 onwards, his dynasty never faced serious danger. Swedes and Norwegians alike were proud of a monarch with a good European reputation. Though the Riksdag of the Estates of 1840 meditated compelling him to supposedly abdicate, he survived that controversy, and his silver jubilee was celebrated with great enthusiasm in 1843.
Charles XIV John died at Stockholm on 8 March 1844. His reign was one of uninterrupted peace, during which his kingdoms experienced great material development. He was succeeded by his son, Oscar I of Sweden and Norway. Oscar's mother was Désirée Clary, Napoleon Bonaparte's first fiancée. Her sister, Julie Clary, was married to Napoleon's brother, Joseph Bonaparte. Désirée chose Napoleon to be prince Oscar's godfather.
The main street of Oslo, Karl Johans gate is named for him, while the Fortress of Karlsborg (Karlsborgs fästning) located in Karlsborg Municipality (Karlsborgs kommun) in Västra Götaland, was named by him after Charles XIII, his adoptive father.
During the French Revolution, Bernadotte belonged for a time to the Jacobin Club, a radical political organization. According to a popular myth, after his death a tattoo was supposedly found on his body that read Mort aux rois! ("Death to kings!"), presumably a legacy of his Jacobin days. However, no evidence has been found to confirm this.