Arkansas authorities must list the names of both same-sex parents on their child’s birth certificate according to a ruling from the Supreme Court on Monday.

Two lesbian couples were involved in the case of Pavan v. Nathaniel Smith. Both couples used anonymous sperm donors to conceive their children, and were denied the ability to put both parents’ names on the birth certificate, even though they do it for straight couples in the case of an anonymous sperm donor.

The case was heard first by the Arkansas Supreme Court, who ruled in the state’s favor. On Monday, the U.S. Supreme Court overruled that. While the ruling was not unanimous, the vote passed 6-3 on the grounds that not listing both same-sex parents on the birth certificate undermined the marriage equality ruling of 2015. 

“As we explained [in Obergefell v. Hodges], a State may not ’exclude same-sex couples from civil marriage on the same terms and conditions as opposite-sex couples.’” the decision read. “Indeed, in listing those terms and conditions—the ’rights, benefits, and responsibilities’ to which same-sex couples, no less than opposite-sex couples, must have access—we expressly identified ’birth and death certificates.’ That was no accident…”

The full ruling is available for review here.