Vitals 101
Vitals 101
@CoreVitals101

Which animations are safe for layout shift (and which aren't)

Not all motion counts against CLS — Cumulative Layout Shift. The metric only cares when an element pushes other content out of the way. So the kind of animation you choose decides whether Google penalizes it.

The key idea: animating an element's position in the layout shoves its neighbors. Animating only how it's painted doesn't.

Safe to animate freely:
— transform (move, scale, rotate) — neighbors don't budge
— opacity — fading never shifts anything

Risky, counts as shift:
— top, left, margin, height — these reflow the page

Think of transform as sliding a sticker across a finished poster, versus re-cutting the whole poster.

Try this: Find one hover or slide-in effect using margin or top and rewrite it with transform: translate(). Same look on screen, zero layout shift counted.
This post was published in the Telegram channel Vitals 101 (@CoreVitals101). All its posts are on the channel page.
Open on Telegram

Latest posts in “Tools and infrastructure”

All channels in this category →

реклама в сети

Готовы запустить рекламу через сеть public.tg?

Новый оффер, продукт, GEO, кейс, событие или партнёрский запуск — соберём маршрут под задачу и отдадим медиаплан.

Telegram для медиаплана: @AFFtop_connect. Быстрый тест: $20 за канал, $1000 за пакет по сети.