Former Barcelona midfielder Xavi has returned to the Spanish club as manager with a contract until 2024.
The Spaniard, 41, has been manager at Qatari club Al Sadd since 2019, but they agreed on Friday to let him join Barca after his release clause was met.
Barcelona say Xavi's contract will run for the rest of the 2021-22 season and two more seasons.
He is expected to arrive back in Spain this weekend and will be officially unveiled on Monday at the Nou Camp.
In a video to fans, the World Cup and two-time European Championship-winning former Spain international said: "It wasn't goodbye, it was 'see you soon'. The Camp Nou has always been my home.
"You're my fans, my people, the club that I love the most. And now, I'm coming home. See you soon, Culers. Forca Barca."
Xavi, who played 767 games and won 25 titles with Barca in his 17 years in the first team, left for Al Sadd in 2015, first joining the club as a player.
He took over as head coach after retiring in 2019 and led them to last season's league title. They are unbeaten in 36 league games.
Since Barcelona sacked Ronald Koeman on 27 October, Xavi has been heavily linked with a return to the Nou Camp where he spent the majority of his illustrious playing career.
Barcelona are ninth in La Liga after winning only four of their opening 11 games, leaving them nine points adrift of leaders Real Sociedad.
The Catalan club has this season struggled under financial pressures, and failed to extend Xavi's former team-mate Lionel Messi's stay because of salary constraints.
Barcelona were unable to spend any money on new signings in the summer, with Memphis Depay, Sergio Aguero and Eric Garcia arriving as free transfers and striker Luuk de Jong joining on loan from Sevilla.
Barca president Joan Laporta has previously said: "I have always said one day [Xavi] will be Barca's head coach but I don't know when."
Source: BBC