CSS Property: position
How a box’s position is calculated.
A box can be positioned with the top
, right
, bottom
, and left
properties. These will have different effects depending on the value of position
.

position: absolute
applied and stacked on top of one another.Possible Values
Value | Description |
---|---|
static | Follows the normal flow in a layout. top , right , bottom , and left have no effect. Default. |
relative | Position is offset from the initial position. |
absolute | Taken out of the flow and positioned in relation to the containing box. |
fixed | Taken out of the flow and positioned in relation to the viewport. It will not scroll with the rest of the page’s content. |
inherit | |
initial | |
unset |
Example
#oogabooga {
position: relative;
left: 1em;
top: 1em;
}