The ship was rescued on Thursday. Photo: Swedish Coast Guard
The large ship ran into trouble on Wednesday in a rural area in the east of Stockholm's archipelago, which is made up of more than 30,000 islands and inlets.
One of its tanks started leaking, oil began spilling into the Baltic Sea and there were worries it could sink.
The vessel had around 52 tonnes of oil on board when it set off on its journey.
But by Thursday the Swedish Coast Guard said it had been towed to safety in the port of Oxelösund, just south of the Swedish capital.
The alarm about the crash was raised at around five o'clock on Wednesday morning. Two environmental protection vessels headed towards the crash site and a plane was sent to fly the area to get an overview of the spill. They were joined by other emergency teams later in the day.
Asked about the problems the oil spill may cause for wildlife in the area, Jonny Åberg from the Swedish Coast Guard told The Local:
"It is too early to know how much damage has been done in the area".
By the afternoon, there were reports that the ship was taking on large quantities of water and might sink.
The ship was surrounded by high waves on Wednesday afternoon. Photo: Swedish Coast Guard
The Stockholm archipelago has been experiencing strong winds and large waves in recent hours.
But the crew on the ship were never in danger, according to the Swedish Coast Guard.
It is the second time this month that Stockholm's scenic archipelago islands have hit the headlines.
Earlier in October Sweden carried out its biggest military operation in decades around the islands, following reports of a mystery foreign submarine lurking in Swedish waters.
The search was called off after the Swedish military said it thought the vessel had moved on.