  We study the Hardy-Littlewood maximal operator in the Musielak-Orlicz-Sobolev
space $W^{1,\varphi}(\mathbb{R}^n)$. Under some natural assumptions on
$\varphi$ we show that the maximal function is bounded and continuous in
$W^{1,\varphi}(\mathbb{R}^n)$.
