It becomes the latest in a number of EU countries to pass such a ban, which mainly affects Muslim women wearing a niqab or burka.
The law was passed by 75 votes to 30 in parliament on Thursday and will come into force on 1 August.
Those violating the ban will be forced to pay 1,000 kroner (£118; $157), with fines ten times higher for repeat offenders.
The wording of the new legislation does not specifically mention Muslim women but says that “anyone who wears a garment that hides the face in public will be punished with a fine”.
Speaking about the law, Denmark’s Justice Minister Søren Pape Poulsen said: “In terms of value, I see a discussion of what kind of society we should have with the roots and culture we have, that we don’t cover our face and eyes, we must be able to see each other and we must also be able to see each other’s facial expressions, it’s a value in Denmark.”
Amnesty International has described the Danish vote as a “discriminatory violation of women’s rights”.
But the European Court of Human Rights last year upheld a Belgian ban on full-face veils, saying that communal harmony trumped the individual’s right to religious expression.
Where else in Europe has similar laws?
France was the first European country to ban the full-face veil in public places in April 2011, seven years after it introduced a law prohibiting conspicuous religious symbols in state schools.
It was followed a few months later by Belgium, which outlawed any clothing that obscures a person’s identity in a public place.
Full or partial bans have since been passed in Austria, Bulgaria and the southern German state of Bavaria, with the Dutch parliament agreeing a ban in late 2016, pending approval from the country’s higher chamber.