Sign up for our COVID-19 newsletter to stay up-to-date on the latest coronavirus news throughout New York City

Elijah is, low-key, our favorite character on “Girls.” Played by acclaimed Broadway actor Andrew Rannells (“Book of Mormon,” “Hamilton,” “Falsettos”), Hannah’s gay ex-boyfriend and current roommate/bestie provides much-needed comic relief and a respite from the girls’ drama.

The 38-year-old actor, who lives in New York City by way of Omaha, Nebraska, talks with us ahead of “Girls” final season about snorting fake cocaine with Lena Dunham and how his sassy character really believes this show is about him.

Related: ‘Girls’ Alex Karpovsky: Ray would flip the f—k out about Trump

So, Elijah got his heart broken at the end of last season.

Majorly. We left him in not the best place. He was getting drunk with Loreen [Hannah’s mom, played by actress Becky Ann Baker] on the street. Maybe not his finest moment.

I was very proud of that storyline, and that Corey Stoll joined us for it, because it was really nice to show that side of Elijah, that he does aspire to have more, to have a relationship.

The Elijah-Hannah dynamic manages to avoid the trope of the stock gay best friend character.

I never felt like I was her sidekick. She always made Elijah feel like he was the star of the show. So, in playing him, I very much felt like I didn’t have to just be the sassy friend. I think in Elijah’s mind, “Girls” is about him. He feels like this is his show. If you were to ask him, he’d be like, “Well, I am the lead of ‘Girls’ and all these girls operate around me.” And that’s how they wrote it. Every scene he’s in, he’s taking charge and being an asshole.

Related: ‘Girls’ Judd Apatow and Jenni Konner defend not getting your sh-t together

His narcissism somehow doesn’t bother me as much as it does with other characters, like Jessa or Marnie.

I know, people have said that to me. I wonder why because I find him to be just as unlikeable in some ways. But I do feel like I had a very specific role in getting to somehow be the voice of the audience. To tell the [girls] off, or say things about them that the audience was thinking: calling them selfish, saying that Marnie’s the worst — I feel like people responded to that.

Any favorite episodes or scenes from your time on the show?

My favorite, selfishly, was getting to do cocaine off a toilet seat with Lena [Season 2, Episode 3, “Bad Friend”]. That whole experience, Lena and I getting to run around the city and act like idiots, and do fake cocaine. Such a funny script and such a crazy episode.

How do you do “fake cocaine”?

It was Vitamin B powder. I do remember there was a weird placebo effect of lining it up and doing it. And because it was Vitamin B, you’d get a little rush from it. We did start to feel high at a certain point. It was silly fun.

You might get asked this a lot, but who is Corey Stoll’s character Dill Harcourt based on?

No one asks me that, actually, I don’t know why. I think he’s a version of a lot of people. For me, I certainly dated people in my mid-twenties who were just a little out of reach, but I thought I was ready for it, but I couldn’t quite do it. I feel like a lot of people have that guy in their past. Their Mr. Big. Dill Harcourt was Elijah’s Mr. Big.

That would fit with Elijah’s delusion that he’s the star of “Girls.”

Yep, he’s Carrie. It’s less that he’s the Hannah. I think he thinks that he’s Carrie Bradshaw. [Laughs]