Timing functions control how an animation progresses over time. They define the acceleration curve, determining whether an animation starts fast and slows down, or starts slow and speeds up.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Aduwoayooluwa/animations/llms.txt
Use this file to discover all available pages before exploring further.
Understanding timing functions
A timing function (also called an easing function) maps the progress of an animation from start to finish. The same animation with different timing functions will feel completely different.Available timing functions
Linear
The animation proceeds at a constant rate from start to finish.- Loading spinners and progress bars
- Continuous rotations
- Mechanical or robotic movements
Ease (default)
Starts slowly, speeds up in the middle, then slows down at the end.- General-purpose animations
- UI transitions
- When unsure which timing to use
Ease-in
Starts slowly and gradually accelerates toward the end.- Elements exiting the screen
- Objects falling or accelerating
- Creating anticipation before a fast action
Ease-out
Starts quickly and decelerates toward the end.- Elements entering the screen
- Buttons responding to clicks
- Modals and dialogs appearing
- Most interactive UI feedback
Ease-in-out
Starts slowly, speeds up in the middle, then slows down again.- Smooth transitions between states
- Page transitions
- Carousel animations
- Hover effects that reverse
React implementation example
Here’s how the Animation Playground demonstrates timing functions:Custom cubic bezier curves
For precise control, you can define custom timing functions using cubic-bezier:Common custom curves
- Bounce
- Snap
- Smooth
Choosing the right timing function
The timing function you choose dramatically affects how your animation feels. Experiment with different options to find what works best.
Decision guide
For entering elements: Useease-out
- Makes elements feel responsive and energetic
- Creates the impression of elements “arriving” at their destination
ease-in
- Elements smoothly accelerate as they leave
- Feels natural for dismissing UI
ease or ease-in-out
- Balanced acceleration works well for toggles
- Symmetrical motion feels polished
linear
- Progress bars need constant speed
- Rotations look better without acceleration
Timing with Framer Motion
Framer Motion provides additional easing options:- Tween (default)
- Spring
- Inertia
Performance considerations
Duration guidelines
- Micro-interactions: 100-200ms
- UI transitions: 200-400ms
- Page transitions: 400-600ms
- Decorative animations: 600-1000ms
ease-out) with shorter durations for responsive UIs.