Framer Motion

Production-ready motion library for React

animation

Simple declarative syntax for complex animations and gestures.

ReactAnimationGesturesLayout

๐ŸŽฎ Playground

import { motion } from "framer-motion"

export default function Demo() {
  return (
    <motion.div
      initial={{ opacity: 0 }}
      animate={{ opacity: 1 }}
      transition={{ duration: 0.5 }}
    >
      Hello World
    </motion.div>
  )
}
Use cases
  • โ€ขPage transitions
  • โ€ขMicro-interactions
  • โ€ขLayout animations
Good for
  • โœ“Modern web apps
  • โœ“Interactive UIs
  • โœ“Landing pages
Not good for
  • โœ—Bundle size sensitive projects
  • โœ—Server-side rendering heavy apps
Installation
$ npm install framer-motion
Example
import { motion } from "framer-motion"

export default function Demo() {
  return (
    <motion.div
      initial={{ opacity: 0 }}
      animate={{ opacity: 1 }}
      transition={{ duration: 0.5 }}
    >
      Hello World
    </motion.div>
  )
}
Comparison

"More intuitive API than React Spring, more features than CSS animations."

Trust Metrics

24.5K

GitHub Stars

5.8M

Weekly Downloads

Last Commit:last year
Used by
FramerStripeNetflix