BERLIN — Germany on Thursday banned the Lebanese militant group Hezbollah from carrying out any activity on its soil and declared the group a terrorist organization, in a move, long sought by Israel and the United States, that deals a blow to its ability to operate in Europe.

Interior Minister Horst Seehofer ordered raids on four mosques and organizations suspected of being linked to Hezbollah, as well as some private addresses, as part of the measures.

“The activities of Hezbollah violate criminal law, and the organization opposes the concept of international understanding, whether in its political, social or military structures,” the interior ministry said in a statement.

Germany, like several other European countries and the European Union as a whole, had previously classed Hezbollah’s military wing as a terrorist group. But it had not applied the designation to the wider organization, which plays a powerful political role in Lebanon, with seats in both Parliament and the cabinet.