Lula to be sworn in as Brazil president as Bolsonaro flies to US
Crowds of people are gathering in the Brazilian capital, Brasilia, ahead of the inauguration of Luiz Inacio Lula da Silva as president.
The veteran left-wing politician, known widely as Lula, also led the country between 2003 and 2010 - and defeated Jair Bolsonaro in October's poll.
There is tight security for Sunday's ceremony amid fears that Bolsonaro supporters may try to disrupt it.
Mr Bolsonaro himself will not attend, having left Brazil on Friday.
A sea of Lula supporters gathered in front of Congress early in the morning - decked out in the red colour of his Workers' Party. They travelled to see their leader sworn in - but also for a celebration.
More than 60 artists - including Samba legend Martinho da Vila - are due to perform on two giant stages decorated in the national flag as part of a music festival dubbed "Lulapalooza".
"Love has won over hate," read one banner carried by a man dressed as Lula - complete with a presidential sash.
"Brazil needed this change, this transformation," said another backer of the incoming leader as she queued for Sunday's festivities.
Juliana Barreto - who is from Lula's home state Pernambuco - told the BBC that her country was "a disaster" previously.
Formal proceedings will begin at 14:30 (17:30 GMT), when Lula and incoming Vice-President Geraldo Alckmin will parade through the city on an open-top convertible.
The men have spent the past days selecting their cabinet and appointing supporters to key state owned businesses.
In a noted change of policy from the Bolsonaro administration, Marina Silva - one of Brazil's best known climate activists - was re-appointed to head the environment and climate ministry. She will be expected to achieve Lula's pledge to reach "zero deforestation" in the Amazon by 2030.
More than 300,000 people are expected to flock to the capital for the inauguration, which will take place at Esplanade of Ministries, home to the country's congress buildings.
The state of Brasilia has pledged to deploy "100%" of its police force - around 8,000 officers - to the city amid fears that some supporters of Mr Bolsonaro could seek to disrupt proceedings.
Mr Bolsonaro himself reportedly flew to the US state of Florida after delivering a teary farewell to supporters.
"We have a great future ahead," he said in a social media video. "Battles are lost, but we will not lose the war."
The populist incumbent has repeatedly said he does not wish to attend the inauguration of his successor, where he would be expected to hand over the presidential sash in a sign of a stable transfer of power.
Last week, authorities arrested a supporter of Mr Bolsonaro who had allegedly placed explosives on a fuel truck near an airport in the capital on Christmas Eve. The man said he hoped to "sow chaos" ahead of Lula's inauguration.
And other supporters of the outgoing leader have remained camped outside army headquarters, where they have been urging the army to launch a coup. Police attempted to remove the demonstrators on Thursday, but withdrew after they reacted violently.
However, Mr Bolsonaro has condemned the protests against his defeat, urging his supporters to "show we are different from the other side, that we respect the norms and the Constitution".