Let K be a number field of degree n over $$\mathbb {Q}$$ . Then the 4-rank of the strict class group of K is at least $$\text {rank}_2 \, ( E_{K}^{+} / E_K^2) - \lfloor n /2 \rfloor $$ where $$E_K$$ and $$ E_{K}^{+} $$ denote the units and the totally positive units of K, respectively, and $$\text {rank}_2$$ is the dimension as an elementary abelian 2-group. In particular, the strict class group of a totally real field K with a totally positive system of fundamental units contains at least $$(n-1)/2$$ (n odd) or $$n/2 -1$$ (n even) independent elements of order 4. We also investigate when units in K are sums of two squares in K or are squares mod 4 in K.