Tilt

3D tilt effect that responds to mouse movement, enhancing UI elements with a dynamic depth effect, customizable rotation factors and spring options.

Examples

Basic Tilt Card

Night Ferry

Short film, 2026

Tilt with Spotlight

Example of the Spotlight component used with the Tilt component.

Low Orbit

Directed by Léa Moreau

Installation

npx shadcn@latest add https://ui.ndekocode.dev/r/motion-tilt.json

Component API

Border Trail

PropTypeDefaultDescription
classNamestringAdditional CSS classes for styling the tilt.
styleMotionStyleAdditional CSS classes for styling the tilt.
rotationFactornumber15Controls the maximum rotation angle in degrees.
isRevesebooleanfalseReverses the tilt effect's rotation direction.
springOptionsSpringOptionsSpring options for the tilt effect.

Credits

Initiated by @AFPedreros