I'm just going to cut most of this from a recent post I made a few days back. If you're interested in the topic then Hazareesingh's work is exactly what you're looking for.
Despite his ultimate defeat at Waterloo, Napoleon was immediately the subject of a sustained cult for most of the 19th C. Almost immediately after his fall from power, a pretty impressive cottage memorabilia industry sprang up to service his memory. In a manner that we'd associate with pop stars, Napoleon's image could soon be found on almost anything, such as cameos, clocks, medals, wallpaper, knives, handkerchiefs, etc. Despite being illegal, such merchandise was smuggled in from Germany and proved highly popular in France. (My favourite story is the popular reports of a hen who laid an egg bearing the Emperor's face - the hen was arrested by the authorities.)
This fuelled, or was the product of, a continuing association by many in France with Bonaparte. Rumours of his return regularly set off local tremors throughout the 1820s and his name remained a lightening rod for agitation. The ideal of Bonapartism (admittedly, not entirely the same as Bonaparte in practice) remained popular and, prior to the Second Empire, Napoleon was easily incorporated into Republican traditions. This, along with the enduring loyalty of his veterans, meant that Bonaparte remained a real political force in France long after his death. Ultimately, his memory and supposed ideals long outlived the Restoration and delivered Louis Napoleon to power.
In short, for decades after his death Napoleon continued to command the admiration and affection of millions in France. This obviously varied somewhat by class and region but, broadly, his image endured and remained a powerful political factor for the better part of a century.
See Sudhir Hazareesingh's The Legend of Napoleon for a review of how the Napoleonic cult survived and adopted to the fall of its originator.
May I ask a follow-up... Why was he exiled rather than executed or other?