“Russian Doll,” on Netflix, opens with a fun party and a tragic death. Nadia Volvokov (a spectacular Natasha Lyonne, wearing so much kohl eyeliner that it’s almost a special effect) is washing her hands in the bathroom at her thirty-sixth-birthday party. It’s a dirty-cool bohemian bash thrown by her friends Maxine and Lizzy, whose loft, in Alphabet City, used to be a yeshiva. In the kitchen, Maxine offers Nadia a joint: “It’s laced with cocaine, like the Israelis do it!” For the hell of it, Nadia picks up a stranger and stops by a bodega—and then, as she’s rescuing her lost cat on the street, she gets hit by a cab. She dies there, sprawled on the pavement.

Then Nadia’s back in the bathroom, washing her hands. Again and again, no matter how much she tries to circumvent her fate, Nadia keeps on dying—tumbling down stairs, taking pratfalls into basements—at unpredictable intervals, inevitably ending up staring at herself in the mirror (and at us, through the camera lens). The fact that she works as a video-game coder does not seem coincidental. Sometimes Nadia makes it to the next day, sometimes not. The premise, right away, appears to be a distaff version of “Groundhog Day,” that classic Zen Buddhist romantic comedy, in which “I Got You, Babe” keeps playing, eternally, at 6 a.m. (In “Russian Doll,” the song is Harry Nilsson’s eerily upbeat “Gotta Get Up”: “Gotta get up, gotta get out, gotta get home, before the morning comes!”)

But “Russian Doll” isn’t a reboot. Scene by scene, it finds raw, affecting themes about mortality and grieving, and it has some legitimately cool plot twists. One will be revealed in this review, so abandon all hope of being completely unspoiled, ye who enter the next paragraph. (Or, if you prefer, go watch the show—which, at eight twenty-five-minute episodes, is as compact as a Kondo’d camisole—and then come back.)

So, anyway, “Groundhog Day” was at heart a compassionate movie about solipsism, about the horror of being trapped inside the self. Phil Connors (Bill Murray) was a one-man guy, to quote the Loudon Wainwright III song, a nihilistic prick who had to evolve into a decent man in order to earn his soul mate (and, also, to become an impressive, accomplished person—a strikingly masculine path to love). In “Russian Doll,” Nadia is hardly St. Teresa: she’s a party girl whose ex-boyfriend broke up his marriage to be with her. But she’s got a grimy charm and a sense of adventure. She’s got real friends, too; she’s more a thrill-seeker than a jerk. And then, a few episodes in, as she spins out, hunting down explanations—Was it that coke-laced joint? Has she gone crazy?—she meets a stranger, Alan (Charlie Barnett), who is standing stoically as an elevator they’re riding threatens to crash to the ground. As everyone else panics, she says, “Didn’t you get the news? We’re about to die.”

“Doesn’t matter,” he tells her. “I die all the time.”

Suddenly, they’re a team. Sometimes apart, sometimes together, Nadia and Alan struggle to trace the origins of their shared glitch. The show expands into a shaggy-dog philosophical mystery, tracing every nook of Alphabet City, sweeping up other colorful characters, exploring red herrings that are as delicious as the main course. Refreshingly, “Russian Doll” isn’t a romantic comedy—Nadia may be a wisecracking hipster and Alan a repressed jock, but they aren’t quite opposites who attract. The show is interested in love, but it’s much more interested, in both jaunty and melancholic ways, in death itself—in the terror of dying, but also in its temptation. Nadia describes her birthday as “staring down mortality like the barrel of a gun”; exiting that bathroom requires pulling the trigger of a gun-shaped doorknob. In its poetic breadth, the series reminded me of the wonderful Kate Atkinson book “Life After Life,” in which a woman keeps on dying, for nearly a century; of “Search Party,” the terrific show about another flawed bohemian solving a New York mystery; of “Fleabag,” that stylized masterwork about a liberated woman’s self-loathing; and even of “The Leftovers,” with its loopy but sincere approach to grief. In other words, it reminded me of all the recent shows I’ve liked best: arch, deeply emotional puzzle boxes, whose visual wit makes them fun but never slight.

You could also compare “Russian Doll” to another Netflix show, from late last year: the eccentric, overpraised “Maniac.” The two series are both surreal, visually immersive fables overseen by detail-oriented people—“Maniac” was directed by Cary Fukunaga; “Russian Doll” was co-created by Leslye Headland, who directed the cult movie “Bachelorette.” They both feature a spitfire woman paired with a psychologically fragile man. But, unlike “Maniac,” which felt quirky without having much to say, “Russian Doll” is propulsive and joyful. The difference is the defining distinction of our moment, between a Netflix show that makes you desperate to press Play and one that you feel obliged to finish.

The other big difference is Lyonne, who finally gets a role worthy of her magnetism. (She also co-created the show with Headland and Amy Poehler, and co-directed and co-wrote some episodes.) Ever since she appeared as a teen in “Slums of Beverly Hills,” Lyonne has been a camera-grabbing presence, so incredibly herself—pop eyes, Mae West crackle, little-tramp slouch—that she burns through every frame, dominating stories even when she’s cast as nothing but the dissolute sidekick, the funny mess no one can straighten up. Here, that same addict persona is the heroine, continually relapsing into death, then getting clean. The actor she reminded me of most was Robert Downey, Jr., another black-humored clown with a special gift for combining slapstick with sexiness, and also someone who, like Lyonne, pours all of his characters into himself, instead of vice versa.

They also share a rough past, a caustic streak, and an air of Bugs Bunny resilience. At one point, Maxine, admiringly, calls Nadia a cockroach: “You can eat anything, take anything, do anything. It’s impossible to destroy you. You will never die.” Nadia is understandably offended, but that idea is the heartbeat of the show—that her character is so alive that she can’t help skirting the edges of existence, tiptoeing up to too much.

Lyonne makes a perfect collaborator for Headland, an underestimated director with a specialty in toxic femininity. Her movies have often been misperceived as nothing but dirty-joke bacchanalia, but they’re richer than that, and she has a particular gift for finding surprise depths in actors, as she did with Kirsten Dunst in “Bachelorette.” “All right,” Nadia says, early on. “Let’s make some choices.” And, in fact, there’s a choose-your-own-adventure delight to Headland’s pacing, a musical pleasure in the repetitions. Minor characters from Episode 1 play major roles later on; throwaway lines that Nadia overheard at that smoky, endlessly rewatchable party suddenly make sense. It never feels like a movie pulled like taffy into a TV format: instead, the cliffhangers work as true emotional pauses, playing off the way that television itself is built on repeated formulas. And yet the story also has a time-warped feel, miraculously leaving space for the characters to just hang out and talk, and allowing side characters—from Jeremy Bobb, as a sleazy professor, to Elizabeth Ashley, as Nadia’s elegant surrogate mother—to feel like whole humans, not plot contrivances.

There’s also something downright elegiac about the show’s portrait of downtown New York, which has a trace of the Scorsese classic “After Hours,” updated for gentrification. Now a homeless shelter coexists with a soulless condo; when some Wall Street bros ask for directions to a club, Nadia steers them, instead, to “a hardware store that closed in 1996.”

“You remember littering?” Nadia asks her ex (a terrific Yul Vazquez), as the two walk down Avenue A. “You remember Dinkins?” he responds. As is the case with many Manhattanites, or maybe anybody who gets older, the city they share is one that no longer exists, full of ghosts only the natives can see. ♦