Why is g is less than p in Diffie-Hellman? In non-authenticated DH, p and g are made as public record. p needs to be a large prime number and g should be smaller than p.  Why does g need to be smaller than p?
It's an element of the field of all integers modulo $p$, and these are represented by the numbers $0,\ldots, p-1$. And $g$ will be one of them.