Somalia (Somali: Soomaaliya; Arabic: الصومال‎), officially called the Federal Republic of Somalia (Somali: Jamhuuriyadda Soomaaliya; Arabic: جمهورية الصومال‎), is a country in Africa. It used to be known as the Somali Republic. It is shaped like the number seven. It is a country in the Horn of Africa. It is bordered by Djibouti to the northwest, Kenya to the southwest, the Gulf of Aden with Yemen to the north, the Guardafui Channel and Somali Sea to the east, and Ethiopia to the west. A person from Somalia is called a Somali.

Somalia is a republic governed by a federal administration with various regional administrations governing on a micro level.

Somalia is an independent country. Since the Somali Civil War in the 1980s, there has been no working government that covers all of Somalia; instead, different clans have been fighting for control. Somalia is now trying to gain control of their people and get back up on its feet with very little resources.

There are four big tribes in Somalia, the Hawiye, the Dirweyn, the Koofur Orsi inhabitants and the Darood.[4] Somalis are a nation of related families, which are called clans. Groups of clans sometimes band together based on a common ancestor or other blood relationship. Sometimes these family relationships date back hundreds or even thousands of years in the past.
Somalis are mostly camel or goat herders, and depend on their livestock to live. In Somalia there are limited sources of drinking water and grazing land, and disputes over grazing rights, water rights, or land in general can lead to fighting between families. Because of the clan system, the families involved will call on their clan for help, leading to a clan war.
The discovery of oil and minerals in Somalia, as well as the power and money associated with politics and business, has created more opportunities for families to get ahead, and has also created more reasons for families to have disputes.

Because Somalia does not have a working legal system, the only help a family in Somalia has to solve a dispute with another family is to get their clan involved. The only solution to the clan wars in Somalia is a working legal system, but the only group who has succeeded in creating one is the Islamic Courts Union. Unfortunately the Islamic Courts Union was accused of being terrorists and Ethiopia invaded Somalia to topple their government and put the government they created in power instead.[source?]

In ancient times, Somalia was a place where people from Egypt and Arabia went to buy Gum Arabic, Myrrh and Ebony Wood. The Ancient Egyptians used to call it Punt, which meant "God's Land". Somalis started herding camel and goats about 4,000 years ago, and they remain mostly herders today.

Visitors from as far away as China visited Somalia, such as Zheng He.

400 more years later, the king of Ethiopia told his subjects that God hated Ifat, and he invaded Ifat with his army, destroying everything he came across and driving the king of Ifat to an island off the coast of Zeila, where he died. The king of Ethiopia then took part of Ifat and added it to his kingdom, and made Ifat pay him lots of money once a year. The remains of Ifat put their kingdom back together again and renamed it Adal.

About a hundred years later, the King of Adal was deposed by an influential warlord by the name of Ahmad ibn Ibrahim al-Ghazi, who had lots of influence with Somali clans across the north. He declared a Jihad against Ethiopia, brought together a huge army that included Turkish musketeers and Somali cavalry. The Somali cavalry were especially deadly because they could shoot arrows while riding their horses, something that the Mongol hordes and Japanese Samurai are also famous for.

Ahmad chose a bad time, however, because the Portuguese Empire was muscling into East Africa. They had taken over the whole east African coast up to Baraawe, and were trying to take over Mogadishu. The Portuguese decided to help out the Ethiopians because the Ethiopians were Christians and the Portuguese did not like Muslims. Ahmad had taken over more than half of Ethiopia when a troop of Portuguese musketeers showed up to help the Ethiopians out. One Portuguese musketeer managed to shoot Ahmad himself, killing him.

A lot of the Somali cavalry was only there because of Ahmad, so the Jihad ended and Ethiopia wound up invading Adal. The Turks had to send an army to stop them from taking over Zeila, and Adal ended up becoming part of the Turkish Ottoman Empire. On those days we do not find the exact people dwell in zeila, but the history ascribed the black people, without tracing their origin and their tribes.
However, some historians attributed Zeila inhabitant were called semaale without farther lucid explanation.

The Turks and Portuguese fought over East Africa for the next 200 years, but the Turks eventually won about 270 years ago. Northern Somalia stayed under Turkish protection after Ahmad died, and the east coast including Mogadishu ended up under the protection of the King of Oman. When Egypt declared independence from the Turks a hundred years later, Northern Somalia became part of Egypt. Egypt came under British protection shortly after that, and northern Somalia basically became a British protectorate as well. This became official about 130 years ago, and northern Somalia officially became British Somaliland.

The Kingdom of Italy had just come together as one country around this time, and wanted the same things that the other big countries had, like colonies. Italy offered to buy the rights to the east Africa coast from Oman, who was in charge of protecting the cities and small kingdoms there, and Oman agreed. Italy made deals with some of the larger kingdoms/sultanates (like the Sultanate of Nugaal) for them to be under Italian protection, but the smaller ones Italy just invaded. This became Italian Somalia in 1905, with capital Mogadishu.

Ethiopia, which had fallen apart again after Ahmad's Jihad, had recently put itself back together again as well, and started invading small Somali kingdoms as well, and by 1890 there were not many left. The French got in on this too, but they just took over a small area which today is Djibouti.

Lots of Somalis did not like what was going on, so a Muslim religious leader named Mohammed Abdullah Hassan started a group called the Darwiish to fight the British, Italians and Ethiopians. The British called him the "Mad Mullah" and spent about 30 years fighting him, eventually using fighter planes against his cavalry. At their height the Darwiish controlled almost a third of Somalia.

Italy created a colony around Mogadishu and enlarged the territory of Italian Somalia after WW1 with the areas south of the Juba river. In the next 20 years the Italian colony grew in importance, having at Hafun the biggest salt production in the world and in the Scebeli river a huge production of bananas exported to Europe. In 1928 was created the first airport in Somalia's capital and later in 1939 was started the longest air route in Africa with the Linea dell'impero, a flight between Rome and Mogadishu.

When Benito Mussolini took power in Italy, he ended the deals he made with the bigger Somali sultanates and invaded them conquering all the area that was to be the colony of Italian Somalia. Then he invaded and took over Ethiopia, using poison gas on the Ethiopians. Shortly afterwards, World War 2 broke out and he invaded British Somaliland, but two years later the British returned and liberated British Somaliland and Ethiopia as well as taking over Italian Somaliland.

After the war, Britain wanted to put all of the places Somalis lived in one country, which would be a British protectorate. The Ethiopians complained that they should be able to keep the areas they conquered, and the Italians also complained the same thing, so in the end the Ethiopians got to keep their bit, and the Italians did too. However, Italian Somaliland was put under a United Nations mandate, so the Italians could not make it a colony.

In 1960 both British and Italian Somaliland declared independence together as the Somali Republic. It was chosen the Latin alphabet for the Somali language.  Many areas where Somalis lived were still part of Britain, Ethiopia and France. Somalia wanted to get back all the areas that had been colonized by the French, Ethiopians and British. Somalia and Ethiopia had a short war in 1964 over the Ethiopian part of Somalia, and it was obvious that more fighting was to come.

In 1969, the President of Somalia was killed by a man whose clan had been hurt by his policies, and General Mohammed Siad Barre took over the country. Siad Barre built a huge army with help from the Soviet Union and when Ethiopia fell for the fourth time (this time because of a Communist takeover) he invaded. The Soviet Union decided that Ethiopia was more important than Somalia and double-crossed Siad Barre, supplying huge amounts of weapons to Ethiopia. Other countries like Cuba and Israel also sent help to Ethiopia, so in the end Siad Barre lost the war.

Ethiopia's new government then began helping Somali rebel groups, who did not like how Siad Barre took over the country, and these rebel groups toppled Siad Barre' government in 1991 and forced him out of the country. After this, however, all of the rebel groups started fighting amongst themselves over who would be in charge now that Siad Barre was gone.

Eventually, some of the rebel groups decided to make their own governments in the land that they controlled. One, called Somaliland, declared independence from Somalia entirely, while another called Puntland declared independence "for now" until a new Somali national government can be put together. Dozens of attempts to create a new national government failed.

Because there was no government in most of Somalia (except where one had been built from scratch, like Puntland and Somaliland) Somalia's only legal system, beyond the law of the gun, was traditional custom and Islamic Sharia law. Because of this, Sharia legal scholars in the lawless south of Somalia gained quite a bit of influence. Around the same time, the people fighting for Somali lands in Ethiopia to be part of Somalia turned to the example of the Afgani Mujahideen, and created their own group called al-Ittihad al-Islamiyya or the Islamic Union. During the 1990s Ethiopia invaded Somalia several times to attack the Islamic Union, who were helping Somali rebels in Ethiopia.

After 2001, the United States of America became very suspicious of both the Sharia courts and the Islamic Union of being terrorists. Warlords made a group called the Alliance for the Restoration of Peace and Counter-Terrorism. The Sharia courts banded together to protect themselves and created the Islamic Courts Union. People liked the Sharia courts and hated the gangsters, so everyone helped the Islamic Courts Union, who defeated the gangsters and drove them out of Mogadishu in 2006. The Islamic Courts Union then formed an army and took over most of southern Somalia.

The United States of America and Ethiopia was alarmed by this takeover, so Ethiopia invaded southern Somalia in 2007 and put a new government in power that was made up of the rebel groups that Ethiopia had funded 15 years earlier. Almost everyone disagreed with this decision, and that same year a rebellion against this new government broke out in Mogadishu and spread across the whole country by 2008. At around the same time, Somali pirates kidnapped westerners from big ships for ransom.