HTML Dog
Skip to navigation

CSS Property: float

How a box should float, shifting it to the right or left with surrounding content flowing around it.

Enlarging, and floating, the first letter of a paragraph.

Possible Values

ValueDescription
noneNo float. Default.
leftFloats the box to the left with surrounding content flowing to the right.
rightFloats the box to the right with surrounding content flowing to the left.
inherit
initial
unset

Example


#boondoggle {
    width: 20em;
    float: left;
}

Browser support