Writer and director John Carney is a master at depicting musicians on the cusp of something special. “Once,” his 2007 music-centered indie film, became a Tony Award-winning musical.

He’s done it again with “Begin Again,” a charming story about second chances.

Keira Knightley and Mark Ruffalo star as the story’s likeable leads. A trio of real-life music stars — Maroon 5 singer Adam Levine, Yasiin Bey (formerly known as Mos Def) and CeeLo Green — act naturally in co-starring roles.

A former professional musician himself, Carney set “Once” in Dublin. He cast Irish singer-songwriter Glen Hansard as a Grafton Street busker whose songs impress a young Czech woman (Markéta Irglová). She helps him rekindle his dream of a music career.

Moving from film to stage, “Once” won eight Tony Awards. It’s a tough act to follow, but “Begin Again” also works as a music-filled story about two creative people who make something beautiful together.

Musical scenes in clubs and recording studios, even simple busking scenes, often seem false on film. But Carney, a former bassist in the Frames, renders such scenes in a genuine way, maybe only as a musician who’s also a fine writer and director can.

For “Begin Again,” Carney moves from Dublin to New York City. Like “Once,” there’s a street musician in this new story, played by British actor James Corden. But Corden’s Steve is just a supporting player. The main storyline features Steve’s friend from England, Gretta (Knightley), and a failing record company executive, Dan (Ruffalo).

Carney plays around with chronology. The film starts closer to its end than its beginning. Steve, a singer-songwriter during at an open mic night, asks Gretta to sing one of her songs. As she sings her sad and pretty song, most people don’t veer from their conversations. But Dan, a producer and arranger who can create “head arrangements,” sees what Gretta’s song can become.

The way Gretta’s performance is largely ignored is one example of Carney getting music right on film. Dan’s disagreements with his smoothly professional business partner, amusingly played by Bey, adds more inside-the-business authenticity. It’s business first, music second.

Dan’s creative heart is in the right place, but he’s also in a state of personal and professional disarray. Drinking, estranged from his wife (Catherine Keener) and teen daughter (“True Grit’s” Hailee Steinfeld) and not signing any artists to his record label for years, he is, in the truest sense of the phrase, not producing.

Ruffalo, playing Dan more as a comedic than tragic character, both slogs and sprints through his role as a once successful producer who loses his way and then, in his darkest hour, finds talent he can believe in.

Like Dan, Gretta is in despair when she meets him. Her story includes a musician boyfriend played by Levine, who performs in the movie. The actress prepared for her own singing scenes by working with a vocal coach. She handily accomplishes this first acting-singing role of career.

Knightley and Ruffalo work so warmly, so comfortably together as Dan and Gretta, as two people with nowhere to go but up. It’s a pleasure to watch their characters progress.

Mixing music and storytelling with apparent ease, Carney makes the voyage Dan and Gretta take in “Begin Again” a cinematic song worth hearing. The creator of “Once” has now, more or less, pulled a very similar story off twice.