In my experience, salaries on Glassdoor seem to be a lot less compared to market rates for many companies. Do companies pay that little, or is it just the basic salary, and stocks etc. are not included?

Why do compensation packages at large (post-IPO) tech companies include appreciable compensation in stock rather than just including all the compensation in the base salary?

Are these two questions paraphrases of each other?
no