Let $m,\,g,\,q \in\mathbb{N}$ with $q\,{\geq}\, 2$ and $(m,q-1)=1$. For $n\in\mathbb{N}$, denote by $s_q(n)$ the sum of digits of $n$ in the $q$-ary digital expansion. Given a polynomial $f$ with integer coefficients, degree $d\ge 1$, and such that $f(\mathbb{N})\subset\mathbb{N}$, it is shown that there exists $C=C(f,m,q)>0$ such that for any $g\in\mathbb{Z}$, and all large $N$, \[|\{ 0\,{\leq}\, n\,{\leq}\, N : s_q(f(n))\md gm\}|\,{\geq}\, CN^{\min(1,2/d!)}\]. In the special case $m=q=2$ and $f(n)=n^2$, the value $C=1/20$ is admissible.