The key to enjoying the delightfully absurd “Wanderlust” is accepting that it does not take place in the real world. Real people have motivations for what they do, and their actions have consequences. “Wanderlust” is populated by characters from a sketch-comedy show who make whatever bizarre decisions are necessary for the premise to play out.

A couple of married urbanites fall on hard financial times and spontaneously move into a commune with a bunch of goofballs? Sure! They engage in the whole “free love” thing without having a real conversation about it first? Why not! A hippy-dippy messianic leader suddenly turns greedy and conniving? Okay!

Normally such thin plotting would be grounds for stern criticism, but not here. For one thing, I suspect that if you told the filmmakers their movie doesn’t make any narrative sense, they would agree with you and say, “So what?” For another thing, the movie is frequently hilarious. You ideally want a comedy to be really funny AND tell a real story, but if you can only achieve one or the other, I’ll take the laughs.

“Wanderlust” comes from the surreally subversive people behind TV cult favorites like “The State” and “Stella.” David Wain is director and co-writer, as he was for “Wet Hot American Summer,” “The Ten,” and “Role Models,” and he shares screenplay credit with regular collaborator Ken Marino. If you’re familiar with any of the titles just mentioned, you’ll have a pretty accurate idea of what to expect here: appearances by Michael Ian Black and Michael Showalter, gags ranging from the satiric to the nonsensical, individual scenes that function as comedy sketches, and a general sense of looseness bordering on anarchy.

Paul Rudd, who’s worked with this team several times before, and Jennifer Aniston, who’s just beginning to test the waters of R-rated comedies (loved her in “Horrible Bosses”), star as George and Linda, a happily married Manhattan couple who can’t afford the city lifestyle anymore. While driving to Atlanta to stay with George’s materialistic, rat-race-loving brother (co-writer Marino), they stumble upon an idyllic rural commune inhabited by a couple dozen hippie types who seem quite content with their way of life. George and Linda are welcomed with open arms.

Is all of this an excuse to make fun of truth circles, smug vegans, and hummus-eating tree-huggers? Yes! The large cast of funny actors create a world of oddball characters, then roam around in that world to see what happens. Seth (Justin Theroux), the commune’s leader, speaks of leaving behind the cares of modern society, but has pagers and fax machines as his point of reference. Carvin (Alan Alda) is the burned-out hippie who founded the place 40 years ago with a bunch of his buddies. Eva (Malin Akerman) is big on the everybody-has-sex-with-everybody aspect. Wayne (Joe Lo Truglio) is a nudist and a winemaker, and the only person in the group who is either of those things. The pregnant Almond (Lauren Ambrose) is married to Rodney (Jordan Peele), and is very proud of the fact that their relationship is biracial. Other characters, like Kerri Kenney-Silver’s Kathy, are like utility players, doing whatever kind of daftness is called for at the moment. Would it be funny to have someone possess no sense of personal boundaries and to sit and watch while George uses the toilet? Okay, in this scene, that’s how Rodney and Kathy are.

There are also some great laughs in the scenes with George’s brother and sister-in-law (Michaela Watkins). The latter hates the joyless drudgery of her McMansion lifestyle as much as her husband loves it, and passes the days drinking margaritas and expressing darkly comic resentment.

For a while George and Linda seem like the sane people in a sea of crazies, but eventually these characters are revealed to be as thinly drawn as the others. I admit that’s a little disappointing, yet I can see the reasoning behind it. No, it doesn’t make any sense that George and Linda would buy into the “open marriage” element of communal living. But unless they do, we can’t enjoy the hilarity that ensues! The movie’s hands are tied, you see. Believe me, a world deprived of the scene where Paul Rudd prepares for a liaison by talking to himself in a mirror would be a sad world indeed.

B+ (1 hr., 38 min.; R, abundant harsh profanity and lots of nudity, some strong sexuality and crude language.)