If you want to rotate, grow, shrink, or shift an element on your webpage, you need to work with transform. This CSS property reshapes how elements are displayed in the browser.
What Exactly Does Transform Do?
The transform property lets you visually manipulate an element without changing its place in the document flow. In other words, you can rotate a box 45 degrees, and while it looks angled to the user, it still “occupies” the same original position in the layout.
The Core Functions
There are several transformations you can apply, and they often combine well together:
translate()
Moves the element without changing the document flow.
rotate()
Rotate the element around its center.
scale()
Enlarges or shrinks the element proportionally.
skew()
Tilts the element horizontally or vertically.
matrix()
A more advanced transform combining multiple effects.
Several transformations can be combined in one declaration:

NOTE: transform doesn’t push or pull other elements around. It only affects how the chosen element is rendered visually. That might seem confusing initially, but it allows smooth animations without disrupting your design.A Live Demo Including transform functions
Here’s a live demo to see each transform function in action. It includes translate(), rotate(), scale(), and skew()—each applied to a colored box with a label.
Hover over each box to see the transformation in action. Play around with the transform values (change degrees, px, scale amounts).
See the Pen Untitled by Lambros (@lampxatzi) on CodePen.
Why Use It?
From interactive buttons that scale on hover, to image galleries with rotating previews, transform allows designers to add style and responsiveness.
It’s lightweight, versatile, and supported across modern browsers.
Combined with CSS transitions, it opens the door to animation without heavy JavaScript.