A linear or radial gradient blends two or three colors in a single direction. A mesh gradient instead drops a color at several points on a canvas and blurs each one heavily so they overlap — the result has no single direction, just color drifting and pooling like fog.
The implementation is simpler than it looks: draw a radial-gradient (solid color fading to transparent) at each point, then blur the whole canvas to erase the hard edges. Slowly moving each point's position over time makes the background feel alive.
Because it is computed fresh instead of exported as a static image, the same code can produce endless different backgrounds just by swapping the color set. It fits anywhere that needs to feel alive without stealing attention — hero section backgrounds, loading screens.
When to use
Use it for hero backgrounds or loading screens that need life without competing for attention. If text sits on top, check contrast carefully.