In Denmark, same-sex sexual activity was legalized in 1933, and since 1977, the age of consent has been equally set to 15, regardless of sexual orientation or gender. Denmark was the first country in the world to grant legal recognition to same-sex unions in the form of registered partnerships in 1989. On 7 June 2012, the law was replaced by a new same-sex marriage law, which came into effect on 15 June 2012. Greenland and the Faroe Islands legalized same-sex marriage in April 2016, and in July 2017 respectively.