Dunga was the captain of Brazil's 1994 World Cup-winning team and coached the national team from 2006 to 2011.
"I am immensely happy to be back," said the 50-year-old, who was the favourite to land the job.
Dunga replaces Luiz Felipe Scolari, who resigned after Brazil reached the semi-finals of the 2014 World Cup, but suffered the joint-heaviest in their history, losing 7-1 to Germany.
Dunga was in charge at the 2010 World Cup in South Africa when Brazil were knocked out in the quarter-finals.
Meanwhile, Argentina coach Alejandro Sabella, 59, will decide his future next week after his side lost 1-0 to Germany in the World Cup final.
Members of the squad have said they want Sabella to remain in charge for the 2015 Copa America in Chile.
"It's down to whether I feel strong enough to give 100%," said Sabella.
"I am immensely happy to be back," said the 50-year-old, who was the favourite to land the job.
Dunga replaces Luiz Felipe Scolari, who resigned after Brazil reached the semi-finals of the 2014 World Cup, but suffered the joint-heaviest in their history, losing 7-1 to Germany.
Dunga was in charge at the 2010 World Cup in South Africa when Brazil were knocked out in the quarter-finals.
Play media
Scolari, who guided Brazil to World Cup victory in 2002, and his entire backroom staff have all
left their posts
since the tournament finished.
Meanwhile, Argentina coach Alejandro Sabella, 59, will decide his future next week after his side lost 1-0 to Germany in the World Cup final.
Members of the squad have said they want Sabella to remain in charge for the 2015 Copa America in Chile.
"It's down to whether I feel strong enough to give 100%," said Sabella.