Correction: An earlier version of this article stated it is illegal to die in Longyearbyen. It is not forbidden to die in Longyearbyen, it’s just unusual as many inhabitants with a serious medical concern will need to receive treatment on the main land as Longyearbyen’s hospital is too small to meet their needs. We have reached out to Terje Carlsen, a communication advisor for the Governor of Svalbard, to address these issues.
Carlsen sent us the following update: It is not illegal to die on Svalbard, that happens from time to time, but as a main rule you cannot be buried here. However, in some special cases and for people who have a special connection or history to Longyearbyen, you can be buried in an urn at the cemetery. Potential viruses from the bodies that died during the Spanish flu is not a worry in Longyearbyen. Some of these bodies were exhumated for scientific purposes in 1998, and you can read some about the results here: https://grupobcc.com/en/speakers/kirsty-duncan/
There have been many reports (including from IFLScience) that the Arctic town of Longyearbyen in Norway's Svalbard Islands has taken the unusual step of outlawing death. Even if you've lived there all your life, if you are terminally ill you will be flown off the island to live out the rest of your days.
However, only part of this is true. Based on an update to IFLScience from Terje Carlsen, a communication advisor for the Governor of Svalbard, it is not illegal to die in Longyearbyen, they just don't have the medical facilities to care for serious medical cases.

The notion it's illegal to die in Longyearbyen may have first started when it was discovered that in 1950 bodies within the town's cemetery were not decomposing due to the permafrost. As a result, it was believed deadly viruses within the bodies could be kept alive and possibly re-infect the living population as the permafrost thawed.
It sounds like a nightmare scenario, but it's one that has already played out elsewhere. In August 2016, there was an anthrax outbreak in northern Siberia, with one boy being killed and around 90 others hospitalized. Furthermore, 2,300 reindeer died from the disease.
The most recent outbreak prior to this took place in 1941. The 2016 outbreak occurred during a heatwave in the region, leading officials to conclude that a reindeer killed by anthrax had thawed out, causing the virus to be released into the environment.
In 1950, officials in Longyearbyen were worried that a similar thing could happen with bacteria and viruses hiding in the residents of their graveyard.
Recently, samples of the Spanish Influenza were found in the lungs of victims of the disease that had been preserved in the permafrost of Alaska, stored there since 1918. Traces were also found in Longyearbyen itself, from a person who died during the 1917 outbreak.
Though it's unlikely that bodies in Longyearbyen thawing out would cause an outbreak of Spanish Flu, a team of scientists studying the virus in 1998 took extra precautions just in case. While extracting samples from the graves, they wore modified spacesuits and ensured that the tissue did not thaw out before it reached a specialized facility in the US.
"Potential viruses from the bodies that died during the Spanish flu is not a worry in Longyearbyen," Carlsen told IFLScience. The results of those scientific studies can be read about here.
"It is not illegal to die on Svalbard, that happens from time to time, but as a main rule you cannot be buried here. However, in some special cases and for people who have a special connection or history to Longyearbyen, you can be buried in an urn at the cemetery."