The vote, by a show of hands, puts the bill on track to become law after technical second readings in both houses.
Senators had on Wednesday approved the crucial first article of the bill granting gay couples the right to marry and to adopt, by a vote of 179 to 157.
Justice Minister Christiane Taubira hailed the Senate vote, saying it had strengthened French society "by granting the simple recognition of full citizenship to homosexual couples".
The bill came under vehement attack in a country that is officially secular but predominantly Catholic, mobilising hundreds of thousands of people in pro- and anti-gay marriage protests nationwide.
In January, hundreds of thousands of demonstrators flooded into Paris for an anti-gay marriage march. Last month, police were forced to fire tear gas on people protesting the bill, and dozens were arrested.
Opponents slam bill
Opponents had said they would organise another mass protest in Paris on 26 May if the law was approved, to demand its withdrawal and a referendum on gay marriage.
The bill was largely supported by the ruling Socialists, their allies in the Green Party and the Communists, and opposed by the main opposition UMP and other right-wing parties.
"We are overwhelmed with pride by this vote to move our society forward," said the head of the Socialists in the Senate, Francois Rebsamen.
But opponents slammed the adoption of the bill, with right-wing former prime minister Jean-Pierre Raffarin saying it would cause a "rupture" in society.
Opposition to the bill has been forceful and gay activists and rights groups say reports of verbal and physical assaults against homosexuals have surged amid the debate.
Rights group SOS Homophobie said this week it had registered a 30% rise in reports of assaults on homosexuals last year compared to 2011, with a marked surge when debate began in the autumn.
Majority in support
Politicians supporting the bill also reported receiving threatening telephone calls and emails, and being heckled by anti-gay activists at public events.
The leaders of the main opposition movement to the bill distanced themselves from these actions, saying they were the work of a radical few.
Opinion polls have routinely indicated that a majority of French people support gay marriage but that a slight majority also oppose adoption rights for homosexual couples.
President Francois Hollande championed same-sex marriage and adoption during his election campaign last year, and his support for the legislation did not waver throughout the turmoil.
His girlfriend, Valerie Trierweiler, has revealed that the president will be attending the marriages of gay friends once the legislation is on the statute books.