Jake Archibald
Read post

Animating zooming using CSS: transform order is important… sometimes

CSS transform animations can produce unexpected 'swooping' effects when using scale followed by translate due to how the browser interpolates transform values. The scale acts as a multiplier for translate values during animation, causing non-linear movement. The solution is to reorder transforms as translate first, then scale, manually multiplying translate values by the scale factor. Alternatively, using separate scale and translate properties ensures proper order. The article also explains why adding rotate(0) accidentally fixes the issue by forcing matrix interpolation.

    #webdev#css#frontend
Jun 17, 2025•7m read time•From jakearchibald.com
Post cover image
Table of contents
What caused the quirky animation?How to fix itBut wait, why did rotate(0) fix it?Bonus round: scale vs 3D translate
10 Impressions
Jake Archibald's image
Jake Archibald

JakeArchibald provides insights into web performance optimization and frontend development best prac...

11 Followers

•

101 Upvotes

Would you recommend this post?

Copy link
WhatsApp
Facebook
X
New Squad
  • © 2026 Daily Dev Ltd.
  • Guidelines
  • Explore
  • Tags
  • Sources
  • Squads
  • Leaderboard