They got off with a little help from their friends.

Beatles Paul McCartney and John Lennon had a real-life Lonely Hearts Club in their youth — when they masturbated together while yelling out, “Brigitte Bardot!” Sir Paul revealed in an eye-poppingly candid new interview published Tuesday.

The bandmates’ very literal take on “Come Together” took place in their pre-fame years at Lennon’s house, alongside maybe three of their friends, McCartney told GQ.

“It was just a group of us,” he said. “And instead of just getting roaring drunk and partying — I don’t even know if we were staying over or anything — we were all just in these chairs, and the lights were out, and somebody started masturbating, so we all did.”

Then people started shouting out names for “inspiration” — until Lennon killed the mood and they let it be.

“We were just, ‘Brigitte Bardot!’ ‘Whoo!’ and then everyone would thrash a bit more,” McCartney told the mag. “I think it was John sort of said, ‘Winston Churchill!’”

McCartney says their very hard day’s night was a “one-off” — “or maybe it was like a two-off” — but didn’t seem like a “big thing” at the time.

“It’s quite raunchy when you think about it,” he said. “There’s so many things like that from when you’re a kid that you look back on and you’re, ‘Did we do that?’ But it was good harmless fun. It didn’t hurt anyone. Not even Brigitte Bardot.”

It wasn’t the only time the “Fap” Four worked it out together. McCartney also weighed in on the legend that they all listened as a 17-year-old George Harrison lost his virginity when the bandmates were sharing a room in Hamburg, Germany — then broke into applause at the end.

“I think that’s true,” McCartney told GQ. “I know we had one bed and two sets of bunks, and if one of the guys brought a girl back, they could just be in the bed with a blanket over them and you wouldn’t really notice much except a little bit of movement. I don’t know whether that was George losing his virginity — it might have been.”

Once, McCartney went on, the lads were so cold while touring in a van in the middle of winter, they lay on top of each other. “We suffered for a while, just shivering, and then someone said: Well, why don’t we . . . ? So we did a Beatles sandwich,” he said. “It warmed us. It was a good idea.”

But he denied the rumors that the drug-loving Liverpudlians were throwing wild orgies at the height of their fame — or at least that he was involved.

“There weren’t really orgies, to my knowledge,” he said. “There were sexual encounters of the celestial kind, and there were groupies.”

Although there was that time he learned that in Sin City, money can, in fact, buy you love.

“There was once when we were in Vegas where the tour guy, a fixer, said, ‘You’re going to Vegas, guys — you want a hooker?’ We were all, ‘Yeah!’ And I requested two. And I had them, and it was a wonderful experience. But that’s the closest I ever came to an orgy.”

McCartney concedes that the “kooky cat” Lennon might have been conducting magical mystery tours of his own bed, however.

“I remember there was someone in a club that he’d met, and they’d gone back to the house because the wife fancied John, wanted to have sex with him, so that happened, and John discovered the husband was watching. That was called ‘kinky’ in those days,” he said.

“So I think maybe John experienced a bit more of that than I did. Tell you the truth, I just didn’t fancy it, that kind of thing. Someone else’s wife? I definitely wouldn’t want the husband to know.”

There’s still a lot of — platonic — love between him and sole surviving bandmate Ringo Starr.

“If Ringo’s anything to go by, we’re great: ‘I love you, man,’ ‘I love you, man,’ and we hug and everything,” he said.