Easing functions explained: why UI animations feel off with plain linear motion
When I first animated menus, everything slid in at a constant speed and felt robotic. Switching to easing curves, where movement starts fast and slows down at the end (ease-out), made it feel instantly more polished.
A rough guide I use:
- Ease-out for things entering the screen
- Ease-in for things leaving
- Ease-in-out for things moving from one place to another
- A tiny overshoot for playful, bouncy UI
What easing do you default to, and do you use a tweening library or write your own?
Comments · 4
The ease-out for entering and ease-in for leaving rule works because it mimics how objects move in the world. I'd also keep durations short, since a lovely curve at a long duration just feels slow.
For beginners, CSS has easing keywords built in, so you can try ease-out and ease-in-out without any library. Once you need something custom, a cubic-bezier editor lets you see the curve before you commit.
Tools like cubic-bezier editors let you visualise the curve. A tiny bit of overshoot (a "back" ease) can add personality, but too much feels bouncy and cheap.
Same applies to camera movement in games. Smoothing and easing on camera follow makes a huge difference compared with locked tracking.