In "Girls Trip," the duo, along with actresses Regina Hall and Tiffany Haddish, play four friends from college who reconnect over a girls weekend in New Orleans at the annual Essence Festival.
For Pinkett Smith, it was a chance to "cut loose" from some of the roles black women have been relegated to on screen.
"I think we’re getting to a place where we’re afforded the opportunity to kind of cut loose and see all the wonderful colors of who we are," the actress told Essence for its July cover story featuring all four stars of the film. "In this film we are flawed, funny, vulnerable and out of our minds! We go way over the top, just to remind people that it’s comedy."
Producer Will Packer compared the R-rated comic romp to "The Hangover" and "Bridesmaids."
"I thought it would be fun to see a film in that vein, with chocolate girls!" he told Essence.
Added director Malcolm Lee ("The Best Man"), "This film is an opportunity for black women to see themselves the way they see themselves and not the way other people see them and not in some trumped-up reality show."
For Latifah it was a chance to act again with her longtime friend Pinkett Smith. Although they have partnered behind the scenes over the years, including on Latifah's now-cancelled daytime talk show, they haven't been on screen since co-starring in 1996's "Set It Off."
"'Are you doing it? If you do it, then I’ll do it,'" Latifah recalled the two of them going back and forth.
The 47-year-old actress also reminisced about her favorite girl's trip.
"My best girl's trip in my 20s was such a turn up, but I think my girls are about ready for another one of those -- minus a lot of real debauchery we might have done in our 20s," she said. "We're all like adults and in relationships and kids like that. So I don't think we'd get as wild as we did back then but we're still capable of getting wild."
"Girl's Trip" also stars comedian Tiffany Haddish, who most recently starred opposite Jordan Peele and Keegan-Michael Key in the comedy film "Keanu." It opens in theaters on July 21.