Why are gradients important in diffusion and osmosis?

Why are gradients important in diffusion and osmosis?