On last night's episode of HBO's Girls, Andrew Rannells' Elijah — Hannah's fairly directionless, very theatrical roommate — finally got an episode largely to himself, as he attended an open audition for the (fictional) musical version of White Men Can't Jump.

He got a call-back, not on the strength of his dancing skills (watch the episode to see Rannells' hilarious attempts at juggling dance moves and basketballs), but on his vocally impressive take on "Let Me Be Your Star," the soaring anthem from NBC's defunct but cult-hit musical theater show, Smash. Rannells chatted with Billboard about Elijah's big audition moment, how Smash made it on to Girls, and his own audition horror stories.

Was it your idea for Elijah to do “Let Me Be Your Star” as his big audition song?

I’m gonna brag and just tell you it was my idea, for better or worse. I talked to Jenni Konner and Lena Dunham and Tami Sagher and Murray Miller, who wrote last night’s episode — we had a couple meetings about what open calls are like, what the whole audition process is like, what I sang in my early years of auditioning and what Elijah would sing.

Then it just hit me: why are we even fucking around, I should just sing a song from Smash! And I knew Jenni would probably go for it, because she loved that show as well. I mean, if we’re auditioning for a musical on a television show, I should probably pay tribute to the television show that was about auditioning for musicals.

Elijah jumps right in singing the climactic, most perilous part of the song. Would he really have to do that in an audition?

In an open-call situation, you generally get sixteen bars, which is not a lot of music, it’s like 20 seconds. And as an actor, you go in and you sing the showiest thing you can sing. You just get up there and do it. For that cut of the song, I sat with an accompanist and figured out if it was better to start at the beginning of the song and just not go as far, or just go for the money notes at the end, and that was what we did. We did sort of have to place it — it’s written for a woman. But I know those are good notes for me, so you kinda go backwards and think, what’s the highest thing I can sing without sounding crazy?

Why was this the right song choice for Elijah at that moment?

After finding out Hannah’s pregnant, it’s a huge wakeup call for him that he has to pull it together. He’s just been trippin’ around without any real direction, and I think it’s just a moment that he knows he has to grow up. Singing that particular song, there’s a certain hunger and desperation to standing in front of someone potentially offering you a job and singing, “Let me be your star.” It felt like a fitting combination for that moment. He’s figuring out what he wants, and what he wants is to be an actor. I was happy that they let me sing it live. My musical theater skills were put to very good use that day!

How based in real-life experience was this scene for you?

The process is real: the idea that you come in and sing, then you read, and depending on the show the final step is “Okay, you can stay and dance.” I told them the story of when I auditioned for the musical Lysistrata Jones – I did it out of town before it came to Broadway. I don’t dance terribly well, but I was holding my own, and then they introduced basketballs, because it’s a show about a basketball team. And I lost my goddamn mind – like, how is it possible that I have to do this? It was the longest afternoon of my life trying to pretend I had these skills. And lo and behold it wound up in that episode! From a sight gag perspective, you don’t get much better than that.

We actually kicked around the idea of trying to just do Lysistrata Jones and to use that as the musical, but then someone came up with White Men Can’t Jump, which is so hilarious, and something that’s not that far off from reality — someone probably has tried that at some point.

What did you use as an audition song when you were starting out, and what do you use now?

Luckily, at this stage in the game, if I go in for something I’m given material from the show. But certainly when I was starting out in musical theater, I always insisted on singing “Born to Run.” I sang it regardless of the show, and sometimes that went over very well, and sometimes it did not! But I always stuck to it: That’s my song. I remember a friend of mine suggesting it, and it sounded good on the piano, which is tricky — not every rock/pop song sounds good translated to a piano — and it was just an unexpected choice. And I love Bruce Springsteen.

The choice of “Let Me Be Your Star” was also such a nice nod to the enduring love for Smash among musical theater fans. Do you find it’s still an obsession in the musical theater community?

I mean, it’s funny — particularly doing Falsettos on Broadway recently with Christian [Borle, who played Tom Levitt on Smash], it made me realize how often I quote that show. And then I became really self-conscious about doing it front of someone who was actually on the show. When we got into tech I said, “Dev, I’m in tech!” [Laughs.] I’m not sure if you recall, but when Karen gets proposed to, she says that.

A couple of weeks ago after we filmed the episode, I realized, “Oh shit – it’s actually going to be on television.” I was nervous about how my friends in musical theater would feel about me doing it. But so far the response has been good. I haven’t heard from Megan [Hilty, who sang the song as Ivy on Smash] actually, but I’ll reach out to her later today. I hope she was pleased and pleasantly honored by our tribute.