Brazilian President Luiz Inacio Lula da Silva believes Fidel Castro is in "impeccable" health and ready to resume his political role in Cuba.
Fidel Castro has not been since in public for months
Lula was speaking after talks in Havana with the 81-year-old Cuban leader, who has not been seen in public for more than 17 months since stomach surgery.
He also signed agreements with the acting Cuban President, Fidel Castro's brother Raul.
These include an aid package worth up to $1bn in credits.
The Brazilian deal will help Cuba increase its food imports and increase investment in infrastructure and oil exploration.
"I think Fidel will soon assume his political role in Cuba, his historic role in Cuba and the globalised world," Lula told reporters before flying out of Havana's international airport.
Lula came to Cuba with Petrobras president Sergio Gabrielli (left)
"He has incredible lucidity and impeccable health... He's as lucid as in his best moments."
During Lula's visit, Cuba secured a commitment from the Brazilian state oil company, Petrobras, to search for oil reserves in Cuban waters.
The 24-hour visit was seen as an attempt by Brazil to improve ties with Cuba, and enhance its regional influence, which has been overshadowed by Venezuelan President Hugo Chavez.
Since the collapse of its main benefactor the Soviet Union, Cuba has struggled to survive, particularly with the US tightening its trade embargo, the BBC's Michael Voss reports from Havana.
Venezuela and China have become its biggest trading partners, offering easy credit terms and subsidised oil.
A number of Lula's closest allies were exiled to Cuba during Brazil's 1964-1985 military dictatorship.
It was the Brazilian president's second visit to the island since taking over the presidency in 2003.
Fidel Castro, 81, has not been seen in public since undergoing a series of intestinal operations.
He has been writing regular newspaper editorials and has been photographed meeting a number of visiting politicians, including Mr Chavez.
The most recent update of Fidel Castro's health came in late December from Raul Castro.
He said his brother was mentally alert, had put on weight and was exercising for two hours twice a day.
Lula and Mr Castro are two of the leading lights of left-wing politics in Latin America, but occupy different parts of the political spectrum, our correspondent adds.
Lula is considered part of what is known as the pragmatic left in Latin America.
He supports a free market economy at home and maintaining good relations with the US - a position radically different from that of Cuba and Hugo Chavez.
There have also been disagreements between Cuba and Brazil over biofuels.
Fidel Castro has written extensively against the use of agricultural crops for biofuels of which Brazil is one of the world's leading producers.