CSS width

Previous Next

Demo of the different values of the width property.

Click the property values below to see the result:

width: auto;
width: 100px;
width: 200px;
width: 50%;
width: 100%;
See this blue div element with different height values.
See this blue div element with different height values.
See this blue div element with different height values.
See this blue div element with different height values.
See this blue div element with different height values.

Play more with the code in our Tryit yourself editor: Try it Yourself ❯