Toronto needed to unload the 25-year-old Brazilian because it was over the MLS limit for designated players. League rules allow for three and Toronto had four with Michael Bradley, Jozy Altidore, Sebastian Giovinco and Gilberto.
Toronto was facing a March 1 roster compliance deadline.
A source tells The Canadian Press that Vasco da Gama has an option to buy Gilberto at the end of the year.
Gilberto has been working out in Brazil, but had been in limbo while the rest of Toronto FC was in training camp.
The five-foot-10 160-pound Brazilian was signed with much hoopla in December 2013 but had limited success in North America.
He had seven goals in 28 league games (21 starts) last season with Toronto.