# Card Flip Animation: 3D Flips That Read Well

> A card flip rotates a card in 3D to reveal its back, which suits flashcards, reveals and before-and-after views. In CSS, put the front and back on two faces, give the parent perspective, rotate the inner element on the Y axis and hide each face's back with backface-visibility. Keep the flip around 400 to 600 ms and give it a non-3D fallback for reduced motion.

Updated November 2026. Source: https://www.exodeui.com/learn/card-flip-animation/

## Key takeaways

- Use flips for two sides of one thing
- Perspective, preserve-3d, two faces and backface-visibility
- Around 400 to 600 ms with a natural curve
- Button trigger, readable content and a crossfade fallback

## When flipping helps

A flip implies two sides of the same thing: a question and its answer, a front and its details, a hidden reward and its reveal. It is less useful for unrelated content or for navigation, where the 3D motion adds time without meaning.

## How it works in CSS

The classic structure is three layers:

- A container with perspective, which sets how strong the 3D effect looks
- An inner element with transform-style: preserve-3d that rotates
- Front and back faces, the back pre-rotated 180 degrees
- backface-visibility: hidden on both faces so only one shows

## Timing and feel

Flips need a little more time than flat transitions because the motion travels through depth, often around 400 to 600 ms. An ease-in-out curve, or a spring with slight overshoot, feels natural. Very low perspective values distort the card; moderate values look more realistic.

## Accessibility

Make the flip trigger a button, and make both sides' content available to screen readers in a sensible order, or announce the change. Under reduced motion, replace the flip with a crossfade. Avoid flipping automatically on a timer.

## Building this in ExodeUI

In ExodeUI, which we make, a flip or reveal is a state transition your code triggers, and springs can add a slight overshoot. For simple flashcards, CSS 3D transforms are enough.

## Frequently asked questions

### How do I make a card flip in CSS?

Use a container with perspective, an inner element with preserve-3d that rotates on Y, two faces and backface-visibility: hidden.

### Why does my flipped card show both sides?

backface-visibility: hidden is missing on the faces, or transform-style: preserve-3d is missing on the rotating element.

### How long should a card flip take?

Around 400 to 600 ms.

### Is a card flip accessible?

It can be, with a button trigger, readable content on both sides and a crossfade for reduced motion.

## Related

- [Best CSS animation libraries](https://www.exodeui.com/best-css-animation-libraries/)
- [Achievement badge animation](https://www.exodeui.com/learn/achievement-badge-animation/)
- [UI animation duration](https://www.exodeui.com/learn/ui-animation-duration/)
- [prefers-reduced-motion guide](https://www.exodeui.com/learn/prefers-reduced-motion-guide/)
