Skip to content

Help us create more tutorials! Make a donation using the Donate button or become a member using the button below to hide this banner and track your progress.

Text transform – CSS

Summary

To change the capitalization of an element’s text using CSS, use the text-transform property:

selector {
  /* uppercase | lowercase | capitalize | none */
  text-transform: uppercase;
}

Details

You can use the following values: uppercase, lowercase, capitalize, and none.

The uppercase value makes all of the letters uppercase.

The lowercase value makes all of the letters lowercase.

The capitalize value makes the first letter of each word capitalized.

The none value does not alter the capitalization of the element(s).

Demo

Exercises

First, recreate the CSS code from the Demo section in your CSS file. Then try changing the value for the property.

Back to: CSS Course > CSS Properties