Oman's Sultan Qaboos bin Said Al Said, one of the Middle East's longest-serving rulers who maintained the country's neutrality in a volatile region, died on Friday.

The 79-year-old leader's cousin Haitham bin Tariq Al Said was named as his successor in a smooth transition of power in the Gulf state.

Oman has declared a three-day period of mourning and the country's flag will be flown at half-mast for 40 days.

More:

With his death, the region lost a seasoned leader seen as the father of modern Oman, who balanced ties between two neighbours locked in a regional struggle, Saudi Arabia to the west and Iran to the north, as well as the United States.

Oman played a crucial role in the negotiations that led to the 2015 Iran nuclear deal, which has been unravelling following President Donald Trump's 2018 decision to withdraw from it and reimpose crippling economic sanctions on Tehran.

Under Qaboos's leadership, the Sultanate also mediated talks between the warring sides in the continuing war in Yemen.

Here are some of the reactions from leaders from around the world at the announcement of Qaboos's passing:

The United Kingdom

British Prime Minister Boris Johnson said he was "deeply saddened" by the death of Qaboos. "He was an exceptionally wise and respected leader who will be missed enormously," he said.

"I had the pleasure of meeting His Majesty Sultan Qaboos and was struck by his commitment to peace and understanding between nations and between faiths."

Johnson noted that Qaboos left behind "a profound legacy, not only in Oman but across the region too".

Iran

Iran's top diplomat said the death of Sultan Qaboos was a "loss for the region" and expressed hopes that relations between the two nations will grow under his successor.

"We offer our dear neighbour Oman our condolences ... [and] we congratulate it for its selection of His Majesty Haitham bin Tariq as sultan, hoping our relations grow as they have before and that the future draws inspiration from the past," Foreign Affairs Minister Mohammad Javad Zarif tweeted in Arabic.

Qatar

Qatar's Emir Tamim bin Hamad Al Thani said Qaboos was a great leader, characterised by wisdom, moderation and long-term vision, The Peninsula news website reported.

The emir added that the late sultan had dedicated his life to serving his Oman and the Muslim ummah, and someone who rejected violence and extremism.

The emir ordered a three day mourning period in the country, according to The Peninsula.

Pakistan

Prime Minister Imran Khan offered his condolences, calling Qaboos "a visionary".

"Oman has lost a beloved leader and Pakistan a close, trusted friend. May his soul rest in eternal peace," Khan said.

I extend our deepest condolences to people of Oman on the passing of His Majesty Sultan Qaboos bin Said al Said. He was a visionary & transformed Oman into a vibrant, modern state.Oman has lost a beloved leader & Pakistan a close, trusted friend.May his soul rest in eternal peace — Imran Khan (@ImranKhanPTI) January 11, 2020

The United Arab Emirates

United Arab Emirates (UAE) ruler Sheikh Khalifa bin Zayed Al Nahyan praised Qaboos for his dedication to serving the Omani people, the country's state news agency WAM reported.

"We express our sincere condolences to the Omani royal family and the people of the sisterly Sultanate of Oman on the death of the great late Sultan Qaboos. We express our full confidence that the people of Oman and its leadership will continue his blessed march serving the causes of the nation and advance the Arab joint action," WAM quoted Al Nahyan as saying.

Abu Dhabi Crown Prince Mohammed bin Zayed Al Nahyan said Oman and the Arab world have lost a "wise leader and a [figure] of great historical stature".

United States

In the US, former President George W Bush issued a statement, saying he and former first lady Laura Bush are saddened by the sultan's death.

"He was a stable force in the Middle East and a strong US ally. His Majesty had a vision for a modern, prosperous, and peaceful Oman, and he willed that vision into reality," Bush said, adding that he and his wife visited him in Muscat last fall.

Turkey

Turkey on Saturday extended condolences to Oman over the death of the longtime ruler.

In a Twitter post, President Recep Tayyip Erdogan said: "I wish Allah's mercy on Sultan of Oman Qaboos bin Said al Said, who was a key figure for Oman's welfare and development with his efforts as well as for the politics in our region."

In a separate tweet, Turkish Minister of Foreign Affairs Mevlut Cavusoglu said: "Heartfelt condolences to the brotherly people of #Oman who lost a visionary leader, His Majesty Sultan Qaboos bin Said Al Said. May his soul rest in eternal peace."

India

Indian Prime Minister Narendra Modi said Qaboos was "a beacon of peace for our region and the world".

"I am deeply saddened to learn about the passing away of His Majesty Sultan Qaboos bin Said al Said. He was a visionary leader and statesman who transformed Oman into a modern and prosperous nation," Modi posted on Twitter.

Modi said Sultan Qaboos was a "true friend of India" and "provided strong leadership for developing a vibrant strategic partnership" between India and Oman.

"I will always cherish the warmth and affection I received from him. May his soul rest in peace," he said.