On 27 October Mozilla released Firefox 159, and one line in its release notes closed a gap web designers have worked around for years: “Scroll-driven animations are now enabled by default.” Two days later web.dev confirmed what that means. With support in Chrome, Safari and now Firefox, scroll-driven animations are Baseline Newly available. A reading progress bar, an image that eases into place as you scroll, a header that settles as the page moves: all of it can now be done in a few lines of CSS, in every major browser, without a JavaScript scroll library.
That is good news, with a catch. Ask an AI tool for “a modern landing page with nice animations” and you already get motion everywhere: every section fading up, every card lifting on hover, numbers counting, logos sliding past. Now that scroll effects are cheap and native, there will be more of it, not less. This guide is about the opposite skill: deciding which motion earns its place, building it so it is smooth and respectful of people who need less of it, and prompting AI tools to do the same.
What scroll-driven animations are, in plain terms
Normal CSS animations run on time: one second, two seconds, done. Scroll-driven animations run on scroll position instead. MDN describes them as animating “along a scroll-based timeline rather than the default time-based document timeline”. There are two kinds of timeline to know:
- Scroll progress with
animation-timeline: scroll(). The animation goes from 0% to 100% as a scroll container, often the whole page, scrolls from top to bottom. This is the reading progress bar. - View progress with
animation-timeline: view(). The animation follows one element as it travels through the visible area. This is the image that fades in as it arrives.animation-rangesets which part of that journey counts, for example only while the element is entering.
Two neighbouring features are easy to confuse with this. View transitions animate between two states of a page, such as a filter change or a move to a detail view; same-document view transitions have been Baseline since Firefox 144 in October 2025. Scroll-triggered animations, which shipped in Chrome 146 in March, are time-based animations that start when you scroll past a point. They are useful, but only Chromium supports them so far, so treat them as an enhancement.
Because scroll-driven animations are only Newly available, some visitors on older browsers will not get them. That is fine as long as the page works and reads correctly without the animation. Wrap the effect in @supports (animation-timeline: scroll()) and design the static state first.
Every animation needs a job
Motion in an interface, scroll-driven animations included, does useful work in a small number of ways. It gives feedback: the button pressed, the item was added. It provides orientation: this panel came from that button, this list item moved there. It shows continuity between two states so the user does not lose their place. And, occasionally, it draws attention to the one thing that matters on a page.
Decoration is not on that list. Anthropic’s own published frontend-design skill, written to steer its models away from generic output, says it directly: fade-and-slide-up entrances on each section and hover transitions on every card “read as AI-generated”. The same file recommends that “a single orchestrated moment” lands better than scattered effects, and that motion which answers a person’s action is welcome when it shows what changed.
That gives a simple test you can apply to any animation an AI tool hands you: what job does this do, and would the user be worse off without it? A cart icon that briefly pulses when an item is added does a job. A testimonial that slides in from the left on scroll usually does not. It only delays the moment the user can read it.

Timing and easing: short, and slowing down at the end
AI-generated motion tends to run long, because slow animations look impressive in a demo. In daily use they feel like waiting. Nielsen Norman Group’s guidance puts most interface animations between 100 and 500 milliseconds, and notes that “it is far more common for animations to be too long than too short”.
Practical numbers to give an AI tool, based on that guidance:
- About 100 ms for small feedback: a toggle, a checkbox, a button press.
- 200 to 300 ms for larger changes, such as a menu or dialog opening.
- Exits a little faster than entrances, for example 300 ms in, 200 ms out.
- Ease-out for things arriving, so they start quickly and settle; ease-in for things leaving; never plain linear for movement on a timer.
Scroll-driven animations are the exception to the easing rule. The visitor’s scrolling already sets the pace, so linear is usually right, and any easing should be built into the keyframes rather than added on top.
A small set of motion values works like colour or spacing tokens. Two or three durations and one or two easing curves, named and reused, make a site feel consistent and stop each component from inventing its own speed. We covered tokens for colour and type in April; motion belongs in the same file.
Prompt · setting motion rules before any animation is built · Source: Written for this article
Before adding any animation to [the site for a ceramics studio in Chania], define motion tokens as CSS custom properties: --motion-fast: [120ms] for feedback (buttons, toggles, checkboxes) --motion-base: [240ms] for opening and closing (menus, dialogs, accordions) --ease-out: [cubic-bezier(0.2, 0, 0, 1)] for entering --ease-in: [cubic-bezier(0.4, 0, 1, 1)] for leaving Rules: - Animate only transform and opacity unless I approve an exception. - No entrance animation on ordinary content sections or cards. - One signature moment only: [the hero image settling into place on first load]. - Motion that answers a user action is allowed when it shows what changed. - Every animation has a reduced-motion version (see below). List each animation you plan, with its job (feedback, orientation, continuity or attention), its token and its reduced-motion behaviour. Wait for my approval before writing code.
Reduced motion is part of the design, not an afterthought
For some people, motion on screen is not a matter of taste. MDN notes that animations “can trigger discomfort for those with vestibular motion disorders”, with scaling and panning of large objects among the common triggers. The W3C’s explanation of WCAG 2.3.3 lists reactions including “dizziness, nausea and headaches”, and specifically mentions parallax, where backgrounds move at a different speed from the foreground. Scroll-driven effects make parallax trivially easy to build, which is exactly why it needs care.
Operating systems let people ask for less motion: Reduce motion on macOS and iOS, Animation effects on Windows, Remove animations on Android. Websites can read that setting through the prefers-reduced-motion media query, which has worked across browsers since January 2020. AI-generated code still often ignores it, or handles it by setting every duration to zero, which can break interfaces that wait for an animation to finish.
Better practice is to replace, not just remove. MDN’s own example swaps a pulsing animation for a gentle dissolve. Large movement becomes a short opacity fade. Parallax becomes a static image. A scroll-linked zoom becomes nothing at all. Feedback can stay, as long as it does not move large areas of the screen.
Two WCAG criteria are worth knowing by name. Pause, Stop, Hide (2.2.2, Level A) requires a way to pause, stop or hide anything that moves automatically for more than five seconds alongside other content, such as an auto-advancing carousel or a scrolling logo strip. Animation from Interactions (2.3.3, Level AAA) asks that motion triggered by interaction can be turned off unless it is essential. Level AAA is not always required, but respecting prefers-reduced-motion is the simplest way to meet its intent.

Prompt · a scroll-driven effect with fallbacks · Source: Written for this article
Add a reading progress bar to the top of [article pages] using CSS scroll-driven animations only. No JavaScript. - A 4px bar in [#b45309], fixed to the top, scaled on the X axis from 0 to 1 with transform: scaleX(), transform-origin: left. - Drive it with animation-timeline: scroll(root) and linear timing. - Wrap everything in @supports (animation-timeline: scroll()). Without support, show no bar at all. - Inside @media (prefers-reduced-motion: reduce), keep the bar but make sure nothing else on the page moves with scroll. - The bar is decorative: aria-hidden="true", and it must not cover the sticky header's focus outline. Then add one view() based reveal for [the gallery images]: opacity 0.4 to 1 only, animation-range: entry 0% cover 30%. No movement, no scaling. Show the complete CSS and explain each block in one line.
Smooth motion: animate what the browser can move cheaply
Motion that stutters is worse than no motion. The web.dev animations guide gives the rule plainly: where possible, restrict animations to opacity and transform. Those two can usually be handled at the compositing stage without recalculating the page layout or repainting it. Moving an element with top and left, animating width or height, or animating shadows and blurs forces more work on every frame, and the same guide notes that anything involving a blur “takes longer to paint”.
AI tools break this rule often, because animating height for an accordion or box-shadow for a hover is the most common way it appears in older code. Watch for three things when you review generated motion:
- Layout properties in keyframes or transitions: top, left, width, height, margin, padding. Ask for a transform-based version.
will-changeon everything. web.dev advises against reaching for it early, because creating extra layers has its own cost. Use it only on an element that is about to animate and actually stutters.- Scroll listeners in JavaScript that set styles on every scroll event. With scroll-driven animations now Baseline, most of these can be replaced with CSS.
Then test on an ordinary mid-range phone, not only on a fast laptop. Motion that is smooth on a developer machine can drop frames on the phones most of your visitors actually use.
Prompt · auditing existing motion · Source: Written for this article
Audit every animation and transition in this CSS and JavaScript. For each one, report: 1. Selector and what triggers it (load, hover, click, scroll, timer). 2. Its job: feedback, orientation, continuity, attention, or none. 3. Duration and easing. Flag anything over 400ms or using linear easing on a timed movement. 4. Properties animated. Flag anything other than transform and opacity. 5. Its prefers-reduced-motion behaviour. Flag anything with none. 6. Whether it runs automatically for more than 5 seconds without a pause control. Then propose: which animations to delete, which to shorten, and a CSS replacement for any JavaScript scroll handler using animation-timeline. Do not change the code until I confirm. [paste CSS and JS]
Prompting for motion that feels like your brand
Motion, like typography, can make a site feel like itself or like everyone else’s. When we wrote about sameness in July, the point was that models fall back to defaults when you give them nothing specific. With motion, the default is the fade-up, and native scroll effects make it even easier to add. To get past it, describe how your brand moves in physical terms. A bakery might move warmly and a little slowly, like dough settling. A law firm might barely move at all, with crisp, short transitions that never draw attention. An outdoor guide might use one confident, wide reveal on the landing image and nothing else.
Ask AI tools to propose two or three motion directions before building, each with its signature moment, its durations and its reduced-motion version, then choose. Be specific about hover, too. Phones and tablets have no hover state, so anything that only appears or explains itself on hover is missing for a large share of visitors. Ask for hover effects inside @media (hover: hover), and make sure the same information is visible without them. And always ask for the static design first. A page that only makes sense once it has animated in has a design problem that motion is hiding.
A review checklist for motion and scroll effects
Before any animated page goes live, check:
- Job. Every animation is feedback, orientation, continuity or deliberate attention. Delete the rest.
- One signature moment at most per page, not an entrance on every section.
- Durations mostly between 100 and 300 ms, exits faster than entrances, ease-out for arrivals.
- Static first. The page reads correctly with every animation turned off and in browsers without support for scroll-driven animations.
- Reduced motion on. Turn on your device’s reduced-motion setting and browse. Large movement, parallax and zooms are replaced or gone.
- Nothing auto-moving for more than five seconds without a pause control.
- Only transform and opacity animate, unless there is a specific, tested reason.
- Real phone test on a mid-range device. No stutter, no layout jumping.
- Content is never waiting. No text is hidden until an animation finishes, so a slow or skipped animation never hides the message.

Less motion, better motion
Native scroll-driven animation is a genuinely useful addition to the web, and it removes a lot of heavy JavaScript. Used with a clear job, short timings and a calm alternative for people who need it, motion makes an interface easier to understand. Used because it is now easy, it makes every site feel like the same template. If you would like help deciding where motion belongs on your site, and where it should stop, get in touch.
Part of our Designing with AI series: one practical guide on the 15th of every month about using AI for interface design, web design and templates, and doing it well.
Keep reading. Previous: Forms and the small details AI gets wrong. All articles in Designing with AI.
Sources
- MDN: Firefox 159 release notes for developers
- web.dev: New to the web platform in October 2026
- MDN: CSS scroll-driven animations
- web.dev: Same-document view transitions are now Baseline Newly available
- Chrome for Developers: New in Chrome 146
- Chrome for Developers: Scroll-triggered animations
- Anthropic: frontend-design skill (SKILL.md)
- Nielsen Norman Group: Executing UX Animations, Duration and Motion Characteristics
- MDN: prefers-reduced-motion
- W3C WAI: Understanding animation from interactions
- W3C WAI: Understanding pause, stop, hide
- web.dev: How to create high-performance CSS animations