AI CSS Animations

CSS Keyframe Animations

90 CSS @keyframes animations for any element: fade, slide, zoom, flip and bounce entrances, and shake, pulse, heartbeat and wobble attention seekers. An animate.css-style library as plain CSS you paste.

How to use these keyframe animations

Open any animation, copy the @keyframes block and the class into your stylesheet, then add the class to the element you want to move: a card, an image, a modal, an icon. The demo box is only there to show the motion.

Entrances and one-shot effects play once when the class is applied, so add the class when the element appears, or toggle it to replay. Change animation-duration, animation-delay and animation-iteration-count on the class to taste; the keyframes stay the same.

Distances are in em, so the motion scales with --kfa-size or the element's font size. Every snippet ships with a prefers-reduced-motion rule that skips to the end state for people who asked their OS for less motion.

Frequently asked questions

What is a CSS keyframe animation?

A named @keyframes rule describes the steps, and the animation property plays them on an element with a duration, easing, delay and repeat count.

How do I make an element fade in with CSS?

Animate opacity from 0 to 1, optionally with a small translate, and set animation-fill-mode: both so the element doesn't flash before the animation starts. The fade entries above are ready to paste.

How do I delay, repeat or keep the last frame of an animation?

Use animation-delay, animation-iteration-count (a number or infinite) and animation-fill-mode: forwards to hold the final frame.

Can I trigger an animation on scroll without JavaScript?

Yes, in browsers with scroll-driven animations: animation-timeline: view() plays the keyframes as the element scrolls into view. Elsewhere the element simply shows its end state. Entries tagged "scroll-triggered" include it.

Should I use a CSS animation or a transition?

Transitions animate between two states when something changes, like a hover or a class. Keyframe animations run on their own, can loop, and can have as many steps as you like.