The United States is withdrawing its Patriot missile system deployed near Turkey's border with Syria when its mandate expires in October.

A joint Turkish and U.S. announcement said Sunday that the air-defense units could be returned to Turkey within a week if the need arises. It said U.S. navy ships would be present in the Mediterranean to support Turkey's defense.

The U.S., Germany and others deployed the batteries in 2013 to protect NATO ally Turkey after shells fired from Syria landed in the country.

The U.S. decision comes a day after Germany said it would withdraw some 250 troops stationed in Turkey when the mandate for their air-defense mission ends next year. Germany said the main threat in the region came from the Islamic State group which doesn't possess missiles.