There’s plenty of reasons to presume “Popstar: Never Stop Never Stopping” won’t work. It’s built off a thin idea about an egotistical pop star and the popular Lonely Island comedy troupe sketches from “Saturday Night Live,” and making an entire movie out of them was a gamble. But in spite of the hurdles (or maybe because of them), “Popstar” is a resounding comedic success, with good-natured humor and a pop-music skewering lens.

060516i Popstar- Never Stop Never StoppingThe story focuses on mega-popstar Conner, aka Conner4Real (played by Andy Samberg), whose fame has gone to his head after splitting with band members (played by Lonely Island creative partners and film directors Akiva Schaffer and Jorma Taccone). Surrounded by people who do anything and everything to keep up Conner’s perpetual state of obliviousness, and with little between his ears outside of one-liners and sound bites, we meet him on the eve of his sophomore album’s release. The pressure couldn’t be higher as Conner does everything in his power to maintain his dwindling superstardom status.

The storyline, however, as is the case in many of these mockumentary comedies, is far from the most important aspect of the film. Instead, everything rests on the shoulders of the jokes, and Samberg, Schaffer and Taccone have written a very funny film that revels in its own stupidity with a playful wink. For those more familiar with the pop-star culture of the moment, there will be more to glean from some of the jokes (plenty at Justin Bieber’s expense), but the film and its jokes work because of how committed the performers are at playing them. Samberg has always coasted on the lines between his goofball personality and foolishness, very easily able to tip the scales from being charmingly ridiculous to being obnoxious, and while his recent series “Brooklyn Nine-Nine” has hit a perfect middle ground where his performance soars, movies have often erred on the obnoxious side of that nature. “Popstar” works so well because Samberg is playing his part of air-headed singer so well that it never comes across as a larger-than-life bit. Aided greatly by fantastic turns from Taccone and Schaffer, the three have a great and natural chemistry that gives way to easy punchlines and laughs.

Although it has more cameos than seems possible (some of which should be left unspoiled until seeing the film), the film doesn’t coast on those moments. Instead, the film’s real asset is its consistency. Running just shy of 90 minutes, the film doesn’t play jokes out longer than they should be, and they introduce enough running gags to build momentum. Many comedies fail by delivering either all of their good jokes in their trailers or, worse, putting all of the funniest moments in the first third of the film (many Judd Apatow films have this problem) and leaving the rest of the film to coast on good will. “Popstar: Never Stop Never Stopping” never relents, even when it seems about to lose its thread. A bonus is that despite some predictability (included a sight gag that happens to Conner mid-performance), there’s enough jokes that happen that come out of left field, keeping the audience on its toes throughout. And when the laughs come, they’re big, using what we know about the characters to build upon the joke.

Of course a big part of The Lonely Island crew and this film in particular is its music, and it doesn’t disappoint; songs such as “I’m So Humble” and “Finest Girl” are absurdly catchy. “Equal Rights” is a hilarious dressing-down of artists (Macklemore) who are late to the social justice cause, as well as a way for Conner to reaffirm his heterosexuality. It’s hard to leave the theater not humming.

In an age of movies where it seems anyone and everyone is complaining about the lack of originality in film, “Popstar” shines bright as a non-sequel comedy that boasts strong comedic performances. There’s a tendency for the film to feel as if it’s a bunch of sketches stitched together, but the underlying storyline of Conner’s reunion with his bandmates is a through line from beginning to end and never distracts from the jokes or slows the momentum to a halt, as is often the case with mockumentaries and comedies that try a bit too hard to inject their jokes with a meaningful plot. “Popstar” is a success because the three friends who created it have a crucial understanding of why it’s important to laugh, and why it’s even more important to sometimes not take things too seriously.