A drag queen, Gloria Vanderbilt and an old lady walk into a nightclub. No, it’s not the punchline of a joke — it’s Studio 54, the decadent nightclub playground that dominated Manhattan in the late 1970s, when the glamorous elite rubbed elbows with plebs and eccentrics while doing “The Hustle.”

And now New York is set to celebrate the famed West 54th Street party venue with a new exhibit that will showcase how Studio 54’s three years of disco dancing and debauchery revolutionized nightlife, fashion, music, culture and society — and how it continues to influence pop culture more than 40 years later.

“Studio 54: Night Magic” will be the first exhibition solely dedicated to the dizzying disco venue when it opens on March 13, 2020, at the Brooklyn Museum.

With nearly 650 objects, including fashion design, an extensive collection of photography, drawings, film and stage sets, on display, the exhibit — incorporating an homage to Studio 54’s lighting — will explore the innovative design and glamorous aesthetics of the historic opera house-turned-nightclub, with original blueprints, sketches and models unseen since the 1970s.

It will also delve into the social politics of the club, founded by Ian Schrager and Steve Rubell, that extend far beyond its infamously tough door policy, where countless clubbers hoping to get past the velvet ropes patiently waited night after night for Rubell or doorman Marc Benecke to grant them access to party with regulars like Andy Warhol, Diana Ross, Elizabeth Taylor, Liza Minnelli, Michael Jackson, Pat Cleveland, Mick Jagger and Truman Capote. (The masses can push past the velvet ropes of the Brooklyn Museum’s “Studio 54: Night Magic” with tickets that go on sale Oct. 8.)

This mixing of the minds led Studio 54 to become a hotbed for revolution, promoting an “anything goes” ethos where music collided with sexuality, drugs, fashion and freedom of expression.

Matthew Yokobosky, senior curator of fashion and material culture at the Brooklyn Museum, tells The Post the storied hot spot picked up where other legendary NYC venues like the Cotton Club left off as a place of mingling for all socio-economic backgrounds.

“Studio 54 has come to represent the visual height of disco-era America: glamorous people in glamorous fashions, surrounded by gleaming lights and glitter, dancing ‘The Hustle’ in an opera house,” Yokobosky says. “At a time of economic crisis, Studio 54 helped New York City to rebrand its image, and set the new gold standard for a dynamic night out. Today the nightclub continues to be a model for social revolution, gender fluidity, and sexual freedom.”

A cornerstone of Studio 54’s legacy is music, and “Studio 54: Night Magic” will highlight the era’s genres including punk, hip-hop and disco with innovative sets and audio elements. Known for its incredible performances and themed parties, a section called “The Studio 54 Experience” will showcase all of the extravagant events including Bianca Jagger’s 30th birthday (where she infamously rode on horseback) and the glamorous 1978 New Year’s Eve party with a performance by Grace Jones.

For the first time since 1977, more than 50 costume sketches by Antonio Lopez for the iconic opening night performance by the Alvin Ailey American Dance Theater will be on view, as well as the fashions of the time and contemporary designs influenced by the era from Michael Kors, Rick Owens and others.

Along with the history of the creation of Studio 54 from masterminds Schrager and Rubell, the exhibition will examine the crash-and-burn demise of the world-famous nightclub, which shuttered its doors in February 1980 as its founders went to prison for tax evasion. “Studio 54: Night Magic” will also chronicle the years following Schrager and Rubell’s release from jail, including the dynamic duo’s comeback with other popular nightclubs, such as Palladium, and the concept of “boutique” hotels.

The exhibit will also include a section dedicated to artists, friends and patrons of Studio 54 who died from AIDS, including Rubell, who succumbed to an AIDS-related health condition in 1989.

No other venue has yet to come close to the behemoth that was Studio 54 and the significant cultural wave it created, and “Night Magic” will show how it continues to revolutionize all facets of life, according to Anne Pasternak, the Brooklyn Museum’s Shelby White and Leon Levy director, who hopes the legacy of the famed nightclub will spark future creative expression.

“At this current moment in history, when struggles for liberation often collide with restrictive social norms, we are excited to present Studio 54: Night Magic,” Pasternak says. “The exhibition encourages visitors to reflect on a significant era in our shared history and challenges us to consider the future, and the many ways we can create a freer and more just world.”

“Studio 54: Night Magic,” on view March 13 through July 5, 2020, at the Brooklyn Museum, 200 Eastern Parkway; BrooklynMuseum.org. Member tickets will be available on Oct. 1, and tickets go on sale to the general public Oct. 8.