German police conducted raids in Berlin and other parts of northern Germany on Thursday in a search for four men suspected of links to Islamic State militants and possibly preparing an attack in Germany, police said.

In close cooperation with the domestic intelligence agency, they arrested two men and one woman on existing warrants related to other matters, they said. German media reported that those arrested were Islamists.

Fears about an attack on German soil have risen since deadly bombings and shootings in Paris in November.

Thursday's raids, carried out in part by special forces, took place on four flats and two offices in Berlin and also in properties in North Rhine-Westphalia and Lower Saxony. Police seized computers, mobile telephones and sketches.

One of the suspects is wanted by Algerian authorities, who believe he is a member of Islamic State, said the Berlin police. He is suspected of having military training in Syria.

Police in Dortmund said they had conducted an operation in the small town of Attendorn in North Rhine-Westphalia but a spokesman declined to give further details. German media reported police as saying that the main suspect was arrested in a shelter for migrants in Attendorn.

German authorities have repeatedly warned of the threat of attacks. They canceled a friendly international soccer match in Hanover last year and closed stations in Munich at New Year due to security concerns.