Ousainou Darboe has been freed along with 18 other detainees, just days after president Yahya Jammeh lost Thursday's presidential election to property developer Adama Barrow.
The men were arrested in April at a demonstration over the alleged death in custody of an activist.
They were each later sentenced to a three-year prison term.
Mr Darboe, leader of the United Democratic Party (UDP), had been due to stand in the presidential election.
However, the Gambian opposition was left without leadership after the April mass-arrest.
A coalition of political parties, including the UDP, then picked Adama Barrow as their single candidate to run against President Jammeh.
Following his shock win on Friday, Mr Barrow heralded a new hope for The Gambia, which is the smallest country on mainland Africa, with a population of fewer than two million.
With the move to free the high-profile prisoners, change in the country seems to be happening at a fast speed.
Amnesty International had been vocal in its criticism of President Jammeh over his human rights record.
Sabrina Mahtani, Amnesty's West Africa Researcher, hailed the release of the 19 political prisoners and called for the charges against them to be dropped altogether.
"The release of the [18 other peaceful protestors] on bail is a big moment for them and their families," Ms Mahtani said.
"We hope that this positive step indicates that they will be fully acquitted in due course."
The prisoners have been released pending an appeal of their jail sentence for "unlawful assembly".
It is unlikely that they would ever be returned to prison as Mr Barrow has vowed to free all political prisoners.

A child welfare agency and hospital in Pennsylvania have paid Elizabeth Mort $143,500 (Â£94,500) for the mistake.
Her three-day old daughter, Isabella, was removed from her for five days in April 2010.
The lawsuit argued that the opiate test in question had a far lower threshold than federal guidelines.
Jameson Hospital failed to inform Ms Mort that she had failed the test, then reported it to Lawrence County children and youth services without a secondary test.
"Elizabeth Mort never imagined that the last thing she ate before giving birth to her daughter - a poppy seed bagel - would lead to the loss of her newborn, but that is exactly what happened after the Jameson Health System failed to account for the possibility that her positive urine drug screen was due to her ingestion of poppy seeds," the lawsuit said.
Child welfare officials arrived the day after the family returned from hospital with an emergency protective custody order and took Isabella.
She was later returned after the agency could find no evidence Ms Mort had used illegal drugs.
The lawsuit, which was filed on her behalf by the American Civil Liberties Union (ACLU), was settled on Tuesday.
ACLU officials said Jameson had changed its policy to ensure newborns were not taken from parents solely on the basis of maternal drug test results.
"We hope that this case will encourage hospitals that routinely test pregnant women for drug use to reconsider that practice due to the harm that can result from false positives," said ACLU lawyer Sara Rose.
A Gambian opposition leader, who had been thrown in jail for taking part in a protest, has been released on bail.
[NEXT_CONCEPT]
A US woman whose newborn was taken from her because she failed a hospital drug test after eating a poppy seed bagel has won a settlement, says her lawyer.