Eritrean President Isaias Afwerki arrived on Thursday for his first-ever visit to Somalia, in another sign of rapidly changing relations in the region following Eritrea's rapprochement with one-time foe Ethiopia.
Somalia President Mohamed Abdullahi's office said in a statement the visit was meant to boost diplomatic relations and explore areas to cooperate in security and investment.
Isaias landed in Mogadishu and headed to the Somali president's office, Reuters witnesses. Security was tight in the capital, they said.
"President Isaias's historic visit is part and parcel of the consultative Tripartite Summits of the Heads of State and Government of Eritrea, Ethiopia and Somalia," Eritrean Information Minister Yemane Meskel said on Twitter.
The three countries have been mending their sometimes fraught relations since Ethiopian Prime Minister Abiy Ahmed took office in April.
In July, Somalia and Eritrea said they planned to establish diplomatic relations as ties improved across the Horn of Africa following Eritrea's rapprochement with Ethiopia.
Past Somali administrations had accused Eritrea of supplying weapons to anti-government Islamist insurgents. Asmara has repeatedly denied this, saying the accusations were concocted by its enemy, Ethiopia.
In 2007, Eritrea walked out of the East African bloc IGAD in protest as Ethiopian forces entered Somalia to fight militants.
The visit comes as Somali President Abdullahi faces an impeachment motion, which was filed in parliament last week.
A copy of the motion, seen by Reuters, lists as grounds for the impeachment an allegation that the president secretly signed agreements with other countries, including Ethiopia and Eritrea.
Abdikarim Haji Buh, the general secretary of Somalia's parliament said in a statement on Tuesday the motion was likely to fail since so far the minimum 92 lawmakers needed for the motion to be valid hadn't been attained.