Danilo has signed a four-year contract with Botafogo, bringing an end to his two-year stint at Forest.
The Brazilian midfielder joined Forest from Palmeiras in 2020 for a fee of £16 million.
During his time at Forest, Danilo made 62 appearances in all competitions, earning the appreciation of the club's management and fans.
The club has expressed gratitude to Danilo for his contributions and wishes him well for the next stage of his career.