Bangladeshi activists have welcomed the abolition of a century-old act which confined leprosy patients to state-run institutions.
The 1898 Lepers Act was passed at a time the authorities believed leprosy was highly contagious. Officials now say the law contravenes human rights.
Correspondents say lepers currently face arrest and a fine if they venture out of their care centres.
Government estimates suggest Bangladesh has about 40,000 leprosy patients.
The BBC's Ethirajan Anbarasan in Dhaka says that leprosy patients have suffered considerable discrimination and humiliation in Bangladeshi society. They have been denied job opportunities and are not allowed to use the public transport system, our correspondent says.
Activists say the move will help integrate patients into society and that from now on leprosy patients can get access to health care in all hospitals.
"It is a first step, it is a first building block towards a leprosy-free Bangladesh. We can now begin the fight against the social stigma and the mindsets which actually says this is a contagious disease," Saber Hossain Chowdhury, an MP from the ruling Awami League, who tabled the bill in parliament, told the BBC's correspondent in Dhaka.
"It doesn't of course solve the problem and it's a problem that will not be solved overnight because it needs awareness and it needs society getting involved and people changing their mindsets and attitudes."
Activists believe the number of people who have leprosy is higher than official figures suggest, as many people do not report the condition because of the social stigma associated with it.
But now that the government has repealed the law, they hope sufferers will be encouraged to come forward for treatment.
Mr Chowdhury said that leprosy can be cured using a multi-drug therapy.
"Through the repeal of this act, this treatment will be available in all hospitals," he said.
But he added: "It is all very well stating that in a law, but we have make sure that this is the case in practice."