CSS translateZ() Function
CSS-Tricks

EDITOR BRIEF
The translateZ() function moves an element along the Z axis, which means closer to or farther from the viewer. It is part of CSS transforms for positioning elements in 3D space.
INSIGHTS
This is useful when learning 3D effects in CSS. Try combining translateZ() with perspective to see how depth changes the layout.
Learn more with these courses
CodeFriends courses that build on this story. Practice in the browser with nothing to install.
- Introduction to HTML, CSS, and JavaScriptLearn the fundamentals of HTML, CSS, and JavaScript, and build your own website from scratch.Beginner25 Hours
- Introduction to Web Development (Light)Master HTML, CSS, and JavaScript in just 10 hours.Beginner10 Hours
- Python Programming 101Learn Python in just 20 hours! Kickstart your programming journey with this beginner-friendly course.Beginner20 Hours
COMMENTS
Loading comments…