A woman and her now-deceased partner were legally married after being together for 50 years, a Utah judge has ruled.

Judge Patrick Corum declared Bonnie Foerster and Beverly Grossaint, who died in May 2018 at the age of 82, were a couple in the eyes of the state despite not having had a registered marriage.

Outside of the courthouse, Ms Foerster said she was “numb from happiness. I’m married. I’m a married woman. I’ve waited 50 years.”

Gay marriage became legal in the state in December 2013, but persistent health problems for both of them prevented them from getting a marriage license though they had held a commitment ceremony.

The last few years, the pair lived in separate facilities due to the medical care both needed, but Ms Foerster was by her wife’s side at the end.

The idea to have their partnership recognised came about weeks after Ms Grossaint’s death.

A longtime friend and the couple’s lawyer, Richard Hoole, suggested to Ms Foerster it was still possible to ‘get married’ - instead of a ceremony, a judge could declare they were legal spouses.

Gay couple left humiliated after being asked to move on Alaska airlines flight so straight couple could sit together

Utah does not recognise common law marriage for any couple, but it is possible to ask a court to recognise the relationship. Ms Foerster and Ms Grossaint’s case is not the first time posthumous marriage has been declared legal.

Mr Hoole said his friends met all the requirements to be legal spouses: they had lived together for decades, they treated each other as spouses, and presented themselves to others as if they were married.

Ms Foerster, who suffers from a rare bone disease which required both her legs to be amputated and is blind due to macular degeneration, made her case to the judge.

She recalled how she met Ms Grossaint in New York City in 1968, shortly after leaving an abusive husband.

30 best pictures from New York Pride Show all 30 1 /30 30 best pictures from New York Pride 30 best pictures from New York Pride Peppermint and Sasha Velour attend the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Revellers standing on Seventh Avenue watch the annual Pride Parade on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride People take part in the annual 2018 New York City Pride Parade on June 24, 2018 as they make their way down 7th Avenue in New York AFP/Getty Images 30 best pictures from New York Pride Parkland, Florida, school shooting survivor Emma Gonzáles attends the 2018 New York City Pride Parade on June 24, 2018 as participants make their way down 7th Avenue in New York AFP/Getty Images 30 best pictures from New York Pride New York City Pride 2018 Getty Images 30 best pictures from New York Pride Members of the New York City Fire Department cheer as EMT Trudy Bermudez and paramedic Tayreen Bonilla get engaged at the annual Pride Parade on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Lady Gaga and Christian Carino are seen at the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Jonathan Van Ness and over 200 marchers show their pride in every flavor at the NYC Pride March on June 24, 2018 in New York City 30 best pictures from New York Pride A general view of atmosphere during the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Billie Jean King attends the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Queen Bee (C) and her fierce flavor posse give an electrifying performance on SMIRNOFFs Love Wins float for the 2018 NYC Pride March on June 24, 2018 in New York City Getty Images for SMIRNOFF 30 best pictures from New York Pride Ilana Glazer attends the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride A general view of atmosphere during the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride A reveller shows off his hat mirroring President Trump's campaign slogan Make America Great Again at the annual Pride Parade on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride A reveller attends the annual Pride Parade on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride An individual mocks Melania Trump's 'I really don't care' jacket, which she wore when visiting a children's shelter on the US-Mexico border Getty Images 30 best pictures from New York Pride A general view of atmosphere during the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Revellers take part in the annual Pride Parade on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Revellers kiss during the annual Pride Parade on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Revellers take part in the annual Pride Parade on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Revellers on the amfAR amazon float as amfAR Celebrates NYC Pride 2018 on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Victoria Justice celebrates on the amfAR amazon float as amfAR Celebrates NYC Pride 2018 on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Gubernatorial candidate Cynthia Nixon makes her way down 7th Avenue during the 2018 New York City Pride Parade on June 24, 2018 AFP/Getty Images 30 best pictures from New York Pride A general view of atmosphere during the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride People take part in the annual 2018 New York City Pride Parade on June 24, 2018 as they make their way down 7th Avenue in New York AFP/Getty Images 30 best pictures from New York Pride A general view of atmosphere during the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride Participants make their way down 7th Avenue during the 2018 New York City Pride Parade on June 24, 2018 AFP/Getty Images 30 best pictures from New York Pride Alexander Wang (center) joins Trojan Condoms to celebrate their Protect Your Wang collaboration, supporing LGBTQ-inclusive sexual health programs, at the NYC Pride March on June 24, 2018 in New York City Getty Images for Trojan 30 best pictures from New York Pride Crowd of parade-goers at amfAR Celebrates NYC Pride 2018 on June 24, 2018 in New York City Getty Images 30 best pictures from New York Pride New York State Governor Andrew Cuomo attends the 2018 New York City Pride March on June 24, 2018 in New York City Getty Images

The pair instantly fell in love and marched in the city’s first gay pride parade together when people threw garbage at them.

They moved to Utah in 1979 to care for Ms Grossaint’s mother and stayed through battles of breast cancer, countless back surgeries, emphysema, and discrimination due to their sexuality.

“We were perfect together. I was born for her and she was born for me,” Ms Foerster said through tears to Mr Corum.

The judge came down from the bench after his ruling to hug Ms Foerster and confirm what had just happened.