Tension heats up between Puntland and Somaliland
Hassan Sheikh, an academic, beat outgoing President Sheikh Sharif Sheikh Ahmed in a run-off poll.
No candidate secured the required two-thirds majority in the first round of voting, conducted by secret ballot.
It is the first time for years that a president has been be chosen on Somali soil, a sign of improving security.
However, the al-Qaeda linked group, al-Shabab, still controls many southern and central parts of the country, and has staged frequent suicide attacks in the capital since it was driven out of Mogadishu last year by African Union troops and pro-government forces.
The two regional states have been at loggerheads over the control of the Sool and Sanaag regions which are located on their border.