President Dilma Rousseff has promised to re-unite Brazil after narrowly winning re-election to a second term in office with 51.6% of the vote.
She said “dialogue” would be her top priority after a bitterly fought campaign against centre-right candidate Aecio Neves, who got 48.4% of the vote.
The left-wing leader said she wanted to be “a much better president than I have been until now”.
She faced mass protests last year against corruption and poor services.
But Ms Rousseff, who has been in power since 2010, remains popular with poor Brazilians thanks to her government’s welfare programmes.
The vote split Latin America’s biggest country almost evenly in two, along lines of social class and geography.
Whereas Dilma Rousseff did well in the poorer northern states, her opponent from the Brazilian Social Democracy Party (PSDB) took many of the wealthier and more developed southern parts of Brazil.
The president said that during the campaign “the word repeated most often was change and the idea most often invoked was reform”.
“Sometimes in history, close outcomes trigger results more quickly than ample victories,” she said.
“It is my hope, or even better, my certainty that the clash of ideas can create room for consensus, and my first words are going to be a call for peace and unity,” she told a cheering crowd in the capital, Brasilia.
“Instead of widening differences and creating a rift, I have the strong hope that we can use this energy to build bridges.”
She also thanked her supporters, especially her political mentor and predecessor in office, Luiz Inacio Lula da Silva.