clear

The clear CSS property sets whether an element must be moved below (cleared) floating elements that precede it. The clear property applies to floating and non-floating elements.

Initial value none
Applies to block-level elements

Syntax

  
clear: both;
  

Values

Is a keyword indicating that the element is not moved down to clear past floating elements.
Is a keyword indicating that the element is moved down to clear past left floats.
Is a keyword indicating that the element is moved down to clear past right floats.
Is a keyword indicating that the element is moved down to clear past both left and right floats.
Is a keyword indicating that the element is moved down to clear floats on start side of its containing block, that is the left floats on ltr scripts and the right floats on rtl scripts.
Is a keyword indicating that the element is moved down to clear floats on end side of its containing block, that is the right floats on ltr scripts and the left floats on rtl scripts.

Browser support

clear112143.51
flow_relative_values55

We use cookies to improve your experience. Learn more in our Privacy policy.

×