When it became apparent that France was going to leave Algeria, the "Pieds-Noirs" (Europeans living in Algeria) left as well. And these were not small numbers, we are talking about well over 1 million people leaving that nascent country in less than a year. This was arguably one of the great migration movements of the second half of the 20th century.
There are a few things to consider:
The "French people" living in Algeria were not necissarily as "French" as you might think. A surprisingly large group hailed from other countries, such as Spain or Italy or maybe Malta. Actual continental French descent was not necessarily the absolute majority amongst the Pieds Noirs. Algerian Jews, though native to the region, are sometimes also counted as Pieds Noirs (for example a lot of them felt compelled to leave as well) but here it's less clear as some of them would not have defined themselves as Pieds Noirs.
This diversity of the Pieds Noirs important if you consider that for example a Pied Noir of distant Spanish descent might not have a home-country to return to, as Spain was still a dictatorship and took a dim view on potential dissidents. And he might not even speak Spanish. So he was forced to leave a country where his family had lived in for generations to leave for another country he had no particular affiliation with. The "exodus" of the Pieds Noirs was a rather sad affair.
And they were still more fortunate than the Algerians who had fought for France during the war (Harkis) and didn't manage to get out of the country in time.
So why did the Pieds-Noirs feel compelled to leave? Part of the negotioations of the French government and the FLN included the status of the Pieds Noirs and they were not necessarily legally required to leave and were guarenteed protection, but they would have to surrender their French citizenship. The French govenment had expected about 100 000 Pieds Noirs to leave for France (again, over 10x as many left)
However, there had been a lot of predictions that it would be far more. The last months of the war were a nightmare of OAS (edit: Organisation armée secrète) terrorism that tried to do as much damage as possible and this came after years of FLN terrorism and massacres. A Pied Noir would know that the FLN had no moral scruples to lynch him and recently the OAS had given them ample reason to seek revenge. Staying in Algeria would seem as an incalculable risk and most people did not take it.
Most Pieds Noirs just left everything they couldn't carry, e.g. cars, houses, and made for the other shore of the Mediterranean, rendering the European quarters of coastal cities ghost towns. A few actually went to the trouble of burning their belongs first rather than to let "them" have it. Sometimes fires were not put out, because the Pieds Noirs elements of the fire brigade were leaving Algeria of well or had already left.
The super-vast majority of the Pieds Noirs resettled in France, although a few went to other countries. E.g. for Pieds Noirs of not-so-distant Spanish stock Spain would have seemed as a logical choice. Mostly they resettled in warm and somewhat arid areas (southern France, Corsica, Spanish coast, ...), similar to Algeria.
There were some Pieds Noirs who stayed (ca. 30 000). There weren't a lot of lynchings. The French had valuable skills that the Algerians could not easily replace and there was an agreement to protect them.
Source: Alistair Horne, A Savage War of Peace: Algeria 1954-1962