Marc Anthony and Lopez
Actress Jennifer Lopez and then-husband Marc Anthony attend the ceremony where producer Simon Fuller was honored with a star on the Walk of Fame in Hollywood, Calif., May 23, 2011. Reuters/Mario Anzuoni

Jennifer Lopez and Marc Anthony have finally divorced after nearly three years of being separated, and have received joint legal custody of their children, media reports said Wednesday.

The divorce was reportedly finalized three months ago in Los Angeles Superior Court but the final judgment was not updated in the system until now, media reports said, citing Judge John Sandoz. Lopez, 44, and Anthony, 45, will reportedly share custody of their 6-year-old twins, Max and Emme. While the “American Idol” judge has received primary custody of the children, the American actor-singer will spend seven days a month with them.

"This was a very difficult decision. We have come to an amicable conclusion on all matters," the former couple reportedly had said, in a joint statement, while announcing their split in July 2011.

According to reports, the two singers tied the knot at home in Beverly Hills in June 2004, just a week after Anthony’s divorce from his first wife -- actress Dayanara Torres -- whom he married in 2000. Anthony filed for divorce from Lopez in April 2012, asking for physical custody of the children. Lopez later filed a response in December 2013 requesting the same.

Lopez was previously married to Cuban chef Ojani Noa from 1997 to 1998 and actor-dancer Cris Judd from 2001 until 2003. The singer, who was dating dancer Casper Smart, reportedly broke up with him in late April, and according to E! News, she discussed the break-up with Anthony before making the decision.

In a recent appearance on The Wendy Williams Show, which is scheduled to air Thursday, Lopez reportedly said that she is "not intimate with anybody at this time," and when asked by the show's host if she was single, she said: "Yes, I've been single for a couple of months."