Why does compound interest matter when most of my investments in stocks/mutual funds don't pay interest?

Might be a dumb question, but I've always wondered this.

Lots of people talk about how important it is to always be regularly investing and building up as early as possible, since doing it early lets you benefit the most from compounding interest effects.

But a mutual fund (which is the number 1 investment everyone recommends) doesn't pay interest (from my understanding). Why do people keep talking about compound interest?