  We generalize R. P. Stanley's celebrated theorem that the $h^\ast$-polynomial
of the Ehrhart series of a rational polytope has nonnegative coefficients and
is monotone under containment of polytopes. We show that these results continue
to hold for weighted Ehrhart series where lattice points are counted with
polynomial weights, as long as the weights are homogeneous polynomials
decomposable as sums of products of linear forms that are nonnegative on the
polytope. We also show nonnegativity of the $h^\ast$-polynomial as a
real-valued function for a larger family of weights.
  We then target the case when the weight function is the square of a single
(arbitrary) linear form. We show stronger results for two-dimensional convex
lattice polygons and give concrete examples showing tightness of the
hypotheses. As an application, we construct a counterexample to a conjecture by
Berg, Jochemko, and Silverstein on Ehrhart tensor polynomials.
