Fluminense have announced they have agreed a five-year deal with Brazil striker Fred.
The 25-year-old on Thursday asked for his contract with French champions Lyon, which was due to expire at the end of the season, to be terminated following a turbulent season with the club.
Fred had been linked with Palmeiras and Fluminense, and the latter today confirmed the forward will join them once the French Football Federation have completed the paperwork surrounding the termination of his Lyon contract.
"Fred will be Fluminense's player for five years," said Flu football manager Alexandre Faria.
"We have agreed a pre-contract which is simply a legal tool necessary in the negotiations. As soon as the contract cancellation with Lyon becomes official we will present the player as ours."
It brings to an end a long-running episode which began a year and a half ago.
Fred, 25, lost his place in Lyon's starting XI at the beginning of last season after breaking his foot on Brazil duty during the Copa America.
On his return to action, he could not oust fellow frontman Karim Benzema from the first team and came close to leaving Les Gones in the transfer window in January 2008.
He decided to stay but was in and out of the Lyon side in 2008.
Family problems and fears for his international ambitions saw him again agitate for a move at the back-end of that year but he could not clinch a transfer away in last month's January window.
Fred, who was suspended by Lyon on February 20, spent just over three-and-a-half years at the Stade Gerland, winning three Ligue 1 titles and one Coupe de France.