Emergency services were alerted at 1.40 pm on Sunday. The station was evacuated and shut down. All trains travelling to and from the central station had to stop and turn around.
The train was parked at a platform and there were no people on board.
A person who works for Swedish national rail operator SJ told the Aftonbladet newspaper that the train was about to be cleaned when the fire erupted.
After the fire broke out, there was a temporary power failure between the Stockholm South and Solna stations.
According to the Swedish Transport Administration (Trafikverket), the breaks on the X2000 train were faulty, which lead to smoke formation and a full-fledged fire then broke out, spreading across two carriages.
The police later speculated that a short-circuit could have sparked the fire.
However, the Greater Stockholm Fire Brigade (Stockholms brandförsvar) said an inquiry would need to establish the precise causes of the fire and to assess how severe the damages are.
By 2.30pm, the fire was under control. Traffic resumed by 3pm, but with severe delays expected for the rest of the afternoon and evening.