Let Hom 0 (Γ, G) be the connected component of the identity of the variety of representations of a finitely generated nilpotent group Γ into a connected reductive complex affine algebraic group G. We determine the mixed Hodge structure on the representation variety Hom 0 (Γ, G) and on the character variety Hom 0 (Γ, G)/ /G. We obtain explicit formulae (both closed and recursive) for the mixed Hodge polynomial of these representation and character varieties.