In theory, the price of a stock reflects the market's expectation of future dividends. In practice, the market expects lots of things that aren't true.
I've come around to the idea that stocks have an intrinsic value as collateral/store of value.
I saw that with a family that owned a condemned property. They couldn't rent it but they sure could borrow against the land price (ever rising) minus the cost of demo'ing the old building.
I also think stocks tend to keep up with/beat inflation and thus are better than cash as a store of value.