To be clear, this isn't just an "acquired taste" that some people find less appetizing than others. People have been evicted from their apartments over the stench and even Swedes only eat it outside. The question then is, why eat it at all?
Surströmming, or rather, fermented fish of various fatty types have a long tradition in Scandinavia. The Norwegian variant, rakfisk, is mentioned as early as 1348. Swedish cured salmon was probably fermented before the combination of dill, salt and sugar became common for curing it in the 19th century as both sugar and salt became cheaper and more common and fermenting became less necessary to preserve the fish.
Fermentation has been a way to control the decay of and preserve food for a long time - remember that all cheese, yoghurt and sourcream are fermented milk and/or cream, that alcohol is fermented sugar (or sugar from starch) and that sourdough bread is based on fermented flour. Likewise, kimchi and sauerkraut are fermented vegetables and Miso is a paste of fermented soy beans. Many Mediterranean cured saucages are fermented and dried (basically all those that have white mold on their surface). The Romans loved their garum, which was the juices of small fish fermented in sea water - and similar fish sauce and many fermented products based on rice, beans, soy and vegtables are still common in southeast Asian cooking.
Herring has been a staple of Swedish cuisine for hundreds, if not thousands of years due to the liberal supply both in the North and Baltic Seas. It is speculated that the current version of surströmming arose either as a mistake or by necessity, or as a planned solution to the lack of salt throught the wars of at the tail end of the clusterfuck that was the Kalmar Union in the early 16th century, as traditionally salted herring was salted too lightly when stored due to the lack of salt and thus started fermenting.
That said, while the smell is strong, the taste is far better. It is salty, sharp and fishy. One needs to remember that surströmming is to be eaten as you would eat many smelly cheeses - in small amounts, with plenty of accessories. A traditional Swedish surströmmingsklämma consists of a sheet of thin crispbread (traditionally baked on rye or barley), butter, slices of hot boiled almond potatoes, chopped onions (red, yellow and/or chives), sourcream and small pieces of cleaned and de-finned (and, if you wish to, de-skinned) surströmming.
The proper way to handle a can of surströmming is to open it outside, either wrapped in a towel or underwater in a bucket, to deal with the high pressure squirt of brine (that is the really smelly part) that results from the surströmming doing the second part of the fermentation in the tin and pour the brine away. Some prefer to rinse the fish off. And yes, the smell is such that it is best to open the can outdoors, although it is traditional to eat it outdoors as the premier (when the previous year's catch is ready) is in August once the brine has been poured way, the fish themselves does not really smell that much and can be eaten indoors.
As to why people eat them? Fermentation has a long tradition to preserve food. Much of it has been forgotten as salt, sugar and refridgeraton had become common in the West and other things you still eat but don't think of it as fermented. People ate it because it was what was available, and like many things it is an acquired taste. As long as you don't open the can indoors, keep the brine and shove whole, uncleaned fish with the innards and fins still on in your mouth.
Sources:
Surströmming, en handbok by Fredrik Ringblom and Örjan Westerlund.
Smaka på historien, by Katarina Schoerner Carr and Örjan Klein.