Under the law anyone who makes a woman observe the custom faces a three-month jail sentence and a $30 (£23) fine.
The practice, known as chhaupadi, has been in the spotlight recently after two women died while sleeping in sheds.
Campaigners say the legislation must be properly enforced, but say behaviour also needs to change.
Under the ancient Hindu practice, women who have their periods or who have just given birth are seen as impure or as bringers of bad luck, and can be forced to sleep in huts or cattle sheds.
Related News :