The Czech Republic has become the first former communist country in Europe to grant legal recognition to same-sex partnerships.
Parliament overturned a veto on the law by President Vaclav Klaus
The vote was passed in parliament by the absolute minimum needed to overturn a veto by President Vaclav Klaus.
He had argued the legislation amounted to excessive regulation by the state of people's private lives.
The law will give gay couples rights to inherit a partner's property and raise children, but does not allow adoption.
The BBC's Rob Cameron in Prague says Czech society is one of the most secular and sexually liberal in Europe.
Homosexual campaigners appear to have the Czech public on their side, he adds.
'Defeat for family'
Although the lower house of parliament approved the legislation in December and the Senate in January, an absolute majority was required to override the presidential veto imposed in February.
The proposal had strong backing from Social Democrat Prime Minister Jiri Paroubek, who said it was key issue ahead of general elections in June.
In a statement released after the vote, Mr Klaus said the result was not a personal defeat but rather "a defeat for all of us who believe that the family in our society is fundamental, unique, unrivalled".
Martin Strachon, a spokesman for the Gay and Lesbian League, told AFP news agency the vote meant gays and lesbians were now recognised as "normal members of society".
"The law is a compromise," said leading gay rights activist Jiri Hromada, quoted by Associated Press. "It will harm no-one and will make many happy."
Parliament has turned down similar proposals four times in the past.