CSS margin-left property

Description

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

Syntax

margin-left : length

Property values

0 length Default

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

margin-left: 0;

+ve length

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

margin-left: 20px;

-ve length

The space on the left side of the border decreases by 20px i.e. it may move on the left side.

margin-left: -20px;

Applicable to

It applies to all elements

#CSS digger
Was this article helpful?

 
arrow
×

Ctrl+D