HTML Dog
Skip to navigation

CSS Value: Percentage

A measurement of relative size. Percentages take the form of a number followed by %.

Percentages can be used by the likes of the width, height, padding, and margin properties as well as font-size.

Example


.flamsipoops {
    font-size: 200%;
    /* font-size is twice the font-size of the containing box */

    width: 50%;
    /* width is one-half the width of the containing box */
}