Motion is one of the most powerful tools in modern web design, and one of the easiest to overdo. A well-timed transition tells people where they are and what just happened. A page where everything bounces, fades and slides at once just feels noisy, and it often feels slow.
The good news is that the platform has finally caught up with what designers have wanted for years. Two features in particular have changed how I build movement into sites: scroll-driven animations and the View Transition API.
Start with the question: what is this motion for?
Before I animate anything, I ask what job the motion does. In my experience it should do one of three things:
- Orient — show where something came from or went to, like a card expanding into a detail view.
- Give feedback — confirm that a click, hover or form submit registered.
- Direct attention — guide the eye to the one thing that matters on the screen.
If an animation doesn’t do one of those, it’s decoration, and decoration should be the first thing cut.
Scroll-driven animations, no JavaScript required
For years, scroll effects meant scroll listeners and libraries that ran on the main thread. CSS scroll-driven animations let you tie a normal keyframe animation to scroll position instead of time, and the browser can run it off the main thread. As of October 2026, with Firefox 159 turning them on by default, they’re supported in Chrome, Safari and Firefox.
@keyframes reveal {
from { opacity: 0; translate: 0 40px; }
to { opacity: 1; translate: 0 0; }
}
.card {
animation: reveal linear both;
animation-timeline: view();
animation-range: entry 0% cover 30%;
}
That’s a scroll-reveal effect in a handful of lines. Reading progress bars, parallax layers and sticky-header shrinks all work the same way.
View transitions make state changes feel connected
The View Transition API animates between two states of a page, such as a filtered grid updating or a thumbnail becoming a full image. Same-document view transitions have been supported across Chrome, Safari and Firefox since late 2025, and you get a smooth cross-fade with almost no code:
document.startViewTransition(() => updateTheDOM());
Give matching elements the same view-transition-name, and the browser animates them from their old position to the new one. It’s the kind of polish that used to take a dedicated animation library.
Timing and easing are the design
Most motion that feels “off” has a timing problem, not a concept problem. A few rules I keep coming back to:
- Keep UI transitions short — roughly 150 to 300ms for small elements, a little longer for large ones.
- Use ease-out curves for things entering the screen, so they arrive fast and settle gently. Something like
cubic-bezier(0.22, 1, 0.36, 1)works well. - Stagger groups of items slightly rather than animating everything at once.
- Animate
transformandopacitywhenever possible; they’re cheap for the browser to render.
Always respect reduced motion
Some people get dizzy or nauseous from large movement on screen, and operating systems let them say so. Honoring that setting isn’t optional — it’s part of building an accessible site.
@media (prefers-reduced-motion: reduce) {
*, *::before, *::after {
animation-duration: 0.01ms !important;
transition-duration: 0.01ms !important;
scroll-behavior: auto !important;
}
}
The takeaway
Good motion is mostly invisible. People don’t notice it; they just feel that the site is responsive and easy to follow. With scroll-driven animations and view transitions now built into every major browser, we can deliver that feeling with less code, better performance and more respect for the people using our sites.