Washington closed its embassy in the midst of the civil war, when the autocrat Siad Barre was overthrown in 1991.
"Today, we reaffirm the relationship between the American people and the Somali people, and between our two nations," said US Ambassador to Somalia Donald Yamamoto in a statement.
"This is a historic and meaningful day, reflecting the progress of Somalia in recent years, as well as a step towards regularizing diplomatic engagement in Mogadishu since the recognition of the Somali federal government in 2013," he said. -he adds.
The United States had restored a "permanent diplomatic presence" in December 2018 in Mogadishu, while the US diplomatic mission for Somalia had until then been attached to the United States Embassy in Nairobi, Kenya.
Somalia has been plunged into chaos since 1991, and since 2007 has had to deal with al-Qaeda-affiliated radical Shebab Islamist insurgents, who carry out numerous attacks against civilian and military targets.
On Monday, these insurgents attacked a military camp used as a launch site for US drones, as well as a convoy of the European Union in Mogadishu.
The United States supports the fight against the Shebab, led by the Somali Federal Government and the African Union force in Somalia (Amisom), which has been active in the country since 2007.
US strikes in Somalia have intensified since April 2017, when President Donald Trump called southern Somalia a "zone of active hostilities".