Published by José Manuel Mateos Terrén
2026-03-30
Advanced SVG Transformations: Containers, ViewBox, and Groups
In previous articles, we learned how to move elements within an SVG graphic, such as rectangles and groups, by modifying their x and y attributes or using matrix transformations (you can review the complete tutorial in our guide on how to move SVG elements). Now, we will take it a step further: we will explore transformations that affect the SVG container, understand the viewBox attribute, and apply transformations to groups and simple elements.