Story highlights

NEW: U.S. State Department says both crews successfully handled the situation

American sailors have helped Iranians at sea in the past

The incident occurred close to the Strait of Hormuz

Piracy is a major problem for international shippers

CNN  — 

Iranian sailors helped scare off armed pirates who attacked an American cargo ship in the Gulf of Oman, Iranian state media reported Thursday.

Iran detains 13 alleged pirates after clash

It’s the latest example of U.S.-Iranian cooperation on pirate-infested high seas despite a wave of tensions between Washington and Tehran over the decades.

EU forces attack pirate targets on Somali shore

The incident occurred northeast of Fujairah, a port for refueling oil tankers, the Fars News Agency said. The port, in the United Arab Emirates, is close to the Strait of Hormuz, an important oil shipping lane.

Iranian navy vessels received a distress signal from the U.S. cargo ship Maersk Texas during patrols.

The forces announced their willingness to help. As they closed in on the American cargo ship, the pirates scattered. The U.S. ship crew thanked the Iranian naval force and continued on its way, state media reported.

“We were aware of the incident yesterday,” a State Department official said. “The situation was successfully deescalated by the ship’s crew and the Iranian crew.”

The United States, Iran and other nations have been intent on repelling pirates operating in the Gulf of Aden and other bodies of water.

Pirate attacks down off Somalia, up off Nigeria

American forces assisted or rescued Iranians at sea several times in January.

U.S. sailors aboard a guided-missile destroyer aided the crew of a sinking Iranian fishing vessel in the Arabian Sea. The U.S. Coast Guard rescued six Iranian mariners at the northern end of the Persian Gulf, the Pentagon said. And the destroyer USS Kidd rescued 13 Iranian sailors from a hijacked fishing boat near the Strait of Hormuz.

Tehran has threatened to close the the strait if sanctions are imposed on its exports of crude oil. The West has been using sanctions and diplomacy to try to stop Iran from producing nuclear weapons.