Are joke episodes common in anime? Episode 101 of Naruto is a joke episode; it is set in between major plot events and revolves around trying to figure out what is under Kakashi's mask. It's also based off of an omake, which are often meant to be funny.

Is it common to have entire episodes dedicated to just a joke, or to have them based off of omake? While omake are relatively inexpensive to make, episodes are expensive, so it seems like this wouldn't be particularly common. Alternatively, it could be a useful way to fill up space in fillers in long anime, many of which I haven't seen. So, is this a common practice?
It depends on the series.

For series who have a guided plot and who have a specific direction they're going in, like Bleach or Naruto, having a comedic episode appear once in a while serves as filler, and something light-hearted for the audience to enjoy.  For instance, non-plot-related episodes of Bleach involving Don Kanon'ji were often joke episodes at intent, and Bleach even did an Arabian Nights' episode in the middle of the major Hueco Mundo plotline.

(I would argue, though, that Kakashi's true face became an ascended meme within the Naruto franchise due to the pervasive curiosity that Naruto and Sakura have when they go to visit him in the hospital, and come this close to actually seeing it.)

Less guided shows like Hayate the Combat Butler have joke episodes embedded and running alongside actual episodes to the extent that it becomes tough to filter out the noise from the signal.  However, with it being a gag anime, and it not getting ever serious (in animation), this is not only par for the course, but to be expected.

I would say that it's not common, but it largely depends on what demographic the show is trying to hit, and how they're portraying themselves - either as a story, plot and resolution-style show, or as a gag show.