When the Beastie Boys first hit it big in 1987, they were seen as “Animal House” frat dudes, thanks to the video for first single “(You Gotta) Fight for Your Right (to Party),” which became an MTV staple.

The clip depicted the guys — Brooklyn native MCA (Adam Yauch) and Manhattanites Ad-Rock (Adam Horovitz) and Mike D (Mike Diamond) — as house-trashing, pie-throwing, oversexed pyromaniacs.

People took it at face value even though, as Horovitz writes in the “Beastie Boys Book” (Spiegel & Grau), out Oct. 30, the Beasties were mocking the very thing they hated: “Sloppy drunk dude trying to creep on young women was repugnant to punks [like us].”

But the joke was on them.

“Unfortunately, when you’re a straight guy in your late teens/early twenties, you can easily fall into the stereotype’s own trappings,” Horovitz writes. “[We] became what we hated.”

In the decades since, the band has apologized repeatedly for their lyrics and behavior from those days, and a fair amount of the book — which is also a love letter to MCA, who died from cancer in 2012 — is devoted to those regrets. Here’s a roundup of some of the Beastie Boys’ wildest, worst early history.

They fired their drummer — for being a girl

From 1981-84, the Beastie Boys featured a Beastie Girl: Kate Schellenbach played drums for the group as they transitioned from punk to hip-hop. “We kicked Kate out of the band because she didn’t fit into our new tough-rapper-guy identity,” Horovitz laments in the book. “Maybe Kate would’ve eventually quit the band because we were starting to act like a bunch of f–kin’ creeps, but it was just s–ty the way it happened. And I am so sorry about it.”

In the book, Schellenbach blames the split on producer Rick Rubin, saying he gave the band an ultimatum of working with him or her. “Part of me was jealous of their success,” she admits, although she knew she wouldn’t have been happy if she had stayed. “What would I be doing when they were rapping about f–king a girl with a Wiffle-ball bat?”

All was eventually forgiven, and the Beasties’ own record label, Grand Royal, released music by Schellenbach’s band Luscious Jackson in the early 1990s.

They almost called their first album something awful

Although Horovitz and Diamond never explain how they landed on the title of their debut 1986 album, ­“Licensed to Ill,” they’re grateful they changed it.

“The original title to this record was ‘Don’t Be a F–got.’ It was Rick Rubin’s idea,” Horovitz reveals in the book. “It was meant to be a joke about jock frat dudes but homophobia’s not funny and we are truly sorry.”

They’re still spending money on a giant penis

“(You Gotta) Fight for Your Right (to Party)” was chosen as a single by the band’s label, Def Jam, in February 1987, even though the Beasties considered it a throwaway. It was immediately picked up by MTV and became a hit, but the band quickly soured on the track and the dumb-jock stereotype it represented — so much so, they never played it live after their 1987 tour.

But one remnant lingers: A giant hydraulic penis that would pop up on stage when the trio played the song. (According to Rolling Stone, it stood 20 feet tall).

“Seemed funny at the time … [But] you gotta really think before you say or do some dumb s–t,” Horovitz writes of the decision to have the prop created. “Think about the people you care about most. Will they be embarrassed for you, and of you? Yes . . . And you’ll end up paying thirty years’ worth of storage locker fees in New Jersey for a 5-foot-by-5-foot dick in a box.”

They inspired car theft

In the “(You Gotta) Fight for Your Right (to Party)” video, Mike D sported a Volkswagen medallion on a thick gold chain. This allegedly led fans across the US and UK to steal the logos right off the grills of VWs. Eventually the carmaker found a way to capitalize on the trend, creating an ad with a photo of a Rabbit missing its hood ornament and the line “Designer labels always get ripped off.”

The company cheekily nodded to the band — “Many [owners] have been heard to out-swear a Beastie Boy (the results of finding their badges have gone missing)” — and offered a free medallion to anyone who asked.

They used to hunt rats in Chinatown

During the mid-80s, Mike D and MCA shared an apartment at 59 Chrystie St. — which was rat-infested because employees of sweatshops on the same floor would leave bags of trash in the hallway.

The landlord suggested the guys take care of the problem by killing one of the vermin and leaving it out to scare off the others.

Some people might go to the hardware store and buy a trap. The Beasties had other ideas.

“We … bought these pellet guns, some CO2 cartridges and a gang of pellets,” Diamond writes.

“Late that night, we rolled in a bit buzzed. We grabbed our loaded pistols … and started kicking the huge garbage bags. Sure enough, rats came streaming out of them. Somehow, we actually nailed a couple, then left them, dead, in the hallway for a few days.”

It worked. As Diamond writes, “Now we were free to go about inviting girls back to our place.”