FANDOM


The float property is used in CSS and certain HTML elements. This property specifies that an element should be taken from the normal flow and placed along the left or right side of its container, where text and inline elements will wrap around it.


Values

Value Description
left The element floats on the left side of its containing block.
right The element floats on the right side of its containing block.
none The element does not float.


HTML example:

<div style="float:left;">Ooh, check this out!</div>


CSS h1 example:

h1 {
    float:left;
}

See Also

External Links