The two people, who are in their twenties, were arrested in the early hours of Thursday in the Älvsborgs harbour part of Gothenburg's port in western Sweden.
Their nationality was not disclosed but they were not Swedish citizens, according to the police.
“For what purpose they had entered the area we do not yet know,” police control room officer Gunilla Gustafsson told the TT newswire.
While police did not link the arrests to previous reports that rising numbers of refugees have been found hiding in the port this summer, they come a month after Gothenburg's harbour hit international headlines.
READ ALSO: Refugees trying to reach UK through Sweden
Officials told Swedish media in August that while staff had long been used to discovering stowaways trying to get into the Nordic country from cargo ships, in 2015 the practice seemed to have been replaced by a trend in the opposite direction, with people desperate to sail away from the biggest port in the Nordics on vessels heading to the UK.
“They are taking big risks, we are afraid that someone will die,” the port's security chief Thomas Fransson told TT at the time.
He said that close to 60 people had been arrested since May after their attempts at hiding in the port were foiled, but said it was unclear how many refugees had successfully made the journey to the UK.
According to Fransson, most of the new wave of secret sailors were from Albania and had sneaked into the high security harbour in Gothenburg by hiding in cargo boxes, truck trailers and even lorry wheel arches.
“We have electric fences, video surveillance and alarm systems. Dogs are also effective. But we have more than 4000 vehicles coming in and out of the port every day and we cannot search them all,” he told TT in August.