Saudi Arabia's stock market snapped a four-day losing streak in late wave of buying on Tuesday, while other major Middle East bourses dropped after the United States imposed sanctions on Iran's leadership.

Saudi Arabia's share index was up 0.6% with gains coming in last 30 minutes of trading. Banks led the late rally with Riyad Bank 1010.SE adding 2.8% and Saudi British Bank climbing 2.7%.

The head of state-run energy giant Saudi Aramco said it could use its spare capacity to meet customer demand, in comments designed to ease concerns over oil supply security caused by recent attacks on oil tankers near the Strait of Hormuz, a key shipping route.

Real estate shares also supported the index rise with Dar Al Arkan Real Estate Development gaining 2.8%.

Saudi Arabia earlier this week launched its new special residency scheme aimed at attracting wealthy and high-skilled foreign workers. The measure will allow expatriate workers freedom of movement, the right to own property and allow them to do business in the kingdom. 

However other major Gulf markets fell after U.S. President Donald Trump targeted Iranian Supreme Leader Ayatollah Ali Khamenei and other top Iranian officials with sanctions on Monday, increasing pressure on Iran after Tehran downed an unmanned American drone. 

Iran said the U.S. move had closed off diplomacy and blamed the United States for abandoning the only route to peace just days after the two foes came within minutes of conflict. 

The Abu Dhabi index closed 0.5% lower, weighed down by a 0.4% drop in Emirates Telecommunications Group and a 0.7% decline in the country's major lender First Abu Dhabi Bank.

In Dubai, the index was also down 0.6%, with blue chip developer Emaar Properties  dropping 1.3% and its top lender Emirates NBD Bank slipping 0.9%.

Qatar's index gave up early gains to trade 0.5% down at close. Petrochemical maker Industries Qatar decreased 1.3% and Qatar Islamic Bank dropped 1.1%.

Egypt's blue-chip index was down 0.3%, to register its sixth consecutive session of losses.

The market has been on the back foot after Egypt's first democratically elected president Mohamed Mursi died while on trial in a Cairo court. His death has triggered calls for an inquiry by Amnesty International and the U.N. Human Rights office.

(Reporting by Shakeel Ahmad in Bengaluru; Editing by Jon Boyle) ((shakeel.ahmad.thomsonreuters.com@reuters.net;))