People sit on the corniche in Doha, Qatar, June 15, 2017. REUTERS/Naseem Zeitoon - RTS178Q0

DUBAI (Reuters) - Economic sanctions imposed on Qatar by three fellow Gulf states do not violate World Trade Organisation agreements, a United Arab Emirates official said, after Doha launched a wide-ranging legal complaint at the Geneva-based body this week.

The UAE, Saudi Arabia and Bahrain cut ties with Qatar - a major global gas supplier and host to the biggest U.S. military base in the Middle East - on June 5, accusing it of backing militant groups and arch foe Iran, allegations Doha denies.

Qatar made the formal protest at the WTO on Monday by “requesting consultations” with the three countries, triggering a 60-day deadline for them to settle the complaint or face litigation at the WTO and potential retaliatory trade sanctions.

“The sanctions imposed by the UAE, Saudi Arabia and Bahrain did not contradict the agreements of the WTO,” UAE state news agency WAM quoted Juma Mohammed al-Kait, an assistant undersecretary in the Economy Ministry, as saying late on Tuesday.

In what appeared to be the first response to the Qatari move, he said the boycott - which included the severing of diplomatic and travel ties - was in line with articles 21 and article 14 of the General Agreement on Trade in Services (GATS), which allows such moves in the case of security exceptions.

The boycotting countries have previously told the WTO they would cite national security to justify their actions against Qatar, using an the almost unprecedented exemption allowed under the WTO rules.

Kait said the agreements did not prevent WTO member states from using economic sanctions to protect basic security interests, or from carrying out the commitments in the United Nations Charter to maintain peace and security, WAM reported.

The WTO suit does not include Egypt, the fourth country involved in the boycott. Western-backed efforts by Gulf state Kuwait to mediate have yielded little progress so far.

The disputed trade restrictions include Gulf bans on trade through Qatar’s ports and travel by Qatari citizens to the three Gulf countries, blockages of Qatari digital services, closure of sea borders and the closure of airspace to Qatari aircraft.