A statement by Copenhagen police said the four had been arrested on Thursday at different addresses in the region of the Danish capital.

All four were suspected of breaking Denmark's terrorism law while in Syria, police said, without giving further information on their identities.

"The suspects have been identified through investigations carried out in close cooperation between the Danish Security and Intelligence Service and Copenhagen police," the statement said.

At one address that was searched on Thursday, police said they had found weapons and ammunition. Police later said on Twitter that a person living at that address had links to one of Copenhagen's criminal gangs.

"The arrests took place as part of the effort against people letting themselves be recruited to terror groups in the war-torn areas in Syria and northern Iraq," police said.

Under Danish terror laws, "letting oneself be recruited to commit acts (of terrorism)" can result in a prison sentence of up to six years.

Prosecutors seek secret hearing

A preliminary hearing is scheduled to be held on Friday. Police said the prosecution would request that the hearing be held behind closed doors, meaning that details revealed there would be barred from publication. Police spokesman Poul Kjeldsen said he could not exclude the possibility of more arrests as the investigation continues.

Kjeldsen said the four had been identified through "close cooperation" between police and the Danish intelligence service. Justice Minister Soren Pind said "it was too early to say" what the suspects might have been planning.

Data shows that 125 people left Denmark to fight in Syria or Iraq, of whom 62 have returned. A Danish-Palestinian gunman killed a filmmaker and Jewish security guard in February last year. He is believed to have been inspired by January's deadly attack on the offices of French satirical magazine Charlie Hebdo.

Europe as a whole is on alert after the Paris attacks in November and last month's bombings in Brussels, both of which were carried out by homegrown attackers who were trained by IS. Some 4,000 Europeans have traveled to Syria or Iraq to join up as foreign fighters for extremist groups, according to a study from International Center for Counter Terrorism in The Hague. Of those, just under a third have returned to their home countries.