In this tutorial we will learn about CSS Measurement Units.CSS Measurement units are used to mention the size of HTML elements in the web page like to mention text size of paragraph element or height and width of image elements. CSS support number of measurement units. Please check the list of various Measurement units below.
List of available measurement units in CSS:
| Unit | Description | Example |
|---|---|---|
| % | Use define element measurement in % | heigth:50% |
| cm | Use to define element measurement in Centimeters | height:10cm |
| px | Use to define element measurement in pixels | height:50px |
| em | Use to define relative measurement for the height of a font in em spaces | height:15em |
| ex | Use to defines a measurement relative to a font’s x-height. | height:10ex |
| in | Use to define element in measurement in inches. | height:1in |
| mm | Use to define element measurement in millimeters | height:50mm |
Parvesh Sandila is a results-driven tech professional with 8+ years of experience in web and mobile development, leadership, and emerging technologies.
After completing his Master’s in Computer Applications (MCA), he began his journey as a programming mentor, guiding 100+ students and helping them build strong foundations in coding. In 2019, he founded Owlbuddy.com, a platform dedicated to providing free, high-quality programming tutorials for aspiring developers.
He then transitioned into a full-time programmer, where his hands-on expertise and problem-solving skills led him to grow into a Team Lead and Technical Project Manager, successfully delivering scalable web and mobile solutions. Today, he works with advanced technologies such as AI systems, RAG architectures, and modern digital solutions, while also collaborating through a strategic partnership with Technobae (UK) to build next-generation products.
