ABOARD THE USS BOXER—President Trump said the U.S. Navy downed an Iranian drone that was flying too close to a U.S. warship in the Strait of Hormuz, hours after Iranian forces said they had seized a foreign tanker, the latest in a series of incidents that have ratcheted up tensions in a vital oil shipping route.

Mr. Trump said the USS Boxer, an amphibious assault ship, took defensive action against the drone, which he said was “threatening the safety of the ship and the ship’s crew” in the Strait of Hormuz, the narrow channel leading into the Persian Gulf through which a third of the world’s seaborne oil is transported.

The drone was “immediately destroyed,” Mr. Trump said. The president called the approach by the drone the latest “of many provocative and hostile actions by Iran against vessels operating in international waters.”

Defense officials wouldn’t say how the drone was downed, but one official said it was an electronic measure. The U.S. Marine Corps within the last year has begun to deploy a system that can detect drones and jam the signal that connects them to their remotely located pilots, forcing them to crash.

Tensions are rising in the region. Earlier in the day, a Wall Street Journal reporter aboard the USS Boxer witnessed close encounters between a group of U.S. ships and the Iranian military.