The agreement was approved with 252 MPs voting for it while one voted against it.
This means the elections will involve 27,775 delegates picked from across the five federal states.
Somalia’s parliament on Saturday approved the electoral model reached last week by President Mohamed Farmaajo and leaders from the five federal states, paving the way for an indirect election.
Some 255 MPs from both Houses of the federal parliament had gathered in Mogadishu to discuss whether to endorse an agreement reached a week ago, which guaranteed a delegate voting system in the coming elections.