Jennifer previously appeared in the season six finale when she sang "Waiting for Tonight" at Karen Walker (Megan Mullally) and Lyle Finster's (John Cleese) wedding, with Jack McFarland (Sean Hayes) acting as one of her backing dancers.
Jennifer Lopez attends the 2017 NBCUniversal Upfront at Radio City Music Hall on May 15, 2017 in New York City.
It also gave Lopez the opportunity to send herself up in hilarious fashion, with her character demanding everybody wear her latest "Glow" perfume.
Jennifer Lopez guest-starred on "Will & Grace" in 2004, during the hit sitcom's original run - and now that the series is back, so is she!
One of her appearances would be as the character of "Shades of Blue", NYPD detective Harlee Santos.
NBC are yet to have revealed further details about what Jennifer will get up to in her forthcoming "Will & Grace" cameo. Their partnership didn't last long, however, but the two became good friends and she even helped him land another gig as a backup dancer for Janet Jackson.
Will & Grace, which originally ran from 1998 to 2006, returned to United States television last year after an 11-year hiatus.
Messing posted a black-and-white pic of her cuddled close to her returning pal.
There's no word yet about when viewers can expect to see the episode, but they can expect to enjoy it whenever they do. Shades of Blue, also on NBC, returns for its third season later this year.