CSS margin-bottom property

Description

It is a longhand property that represents margin area on the bottom side of the border box.

Syntax

margin-bottom : length

Property values

0 lengthDefault

There is no thickness of the margin area on the bottom side of the border box.

margin-bottom: 0;

+ve length

There is 20px space on the bottom side of the box.

margin-bottom: 20px;

-ve length

The space on the bottom side of the border decreases by 20px i.e. the content below this box may merge into this box.

margin-bottom: -20px;

Applicable to

It applies to all elements

#CSS digger
Was this article helpful?

 
It is a block-level element.
This text flows below the block-level box.
×

Ctrl+D