Particle MorphMotion · ZainSpire ← Library

Canvas particles · shape morphing · your own word

Thousands of points.
One shape at a time.

Every glowing point knows where it belongs in the next shape. A heart turns into a butterfly, the butterfly into a flower, the flower into your word. Run your mouse or finger through them and they scatter like dust, then drift back home.

heart
HTML · CSS · JavaScript · no librariesDownload the code ↓

Where the points go

Sampled from a mask

Each shape is drawn once on a hidden canvas. The script picks random pixels inside it, one per particle, so every point gets a home. When the shape changes, each point simply gets a new home.

How they move

A spring with a little drag

Every frame each particle is pulled toward its home and slowed down a bit, so it overshoots softly and settles. Each one waits a tiny random delay first, which is why the shape seems to flow instead of jump.

Touch it

Your cursor pushes them away

Particles near the pointer get a push outward. Let go and the spring brings them back. Type a word and press Morph to make your name the last shape in the loop.