...

/

How to Position Backgrounds in CSS

How to Position Backgrounds in CSS

Backgrounds in CSS may be positioned with keywords or percentage values. Let's take a look at how it works.

We'll cover the following...

Positioning Backgrounds with Keywords.

Backgrounds may be positioned with the combination of the keywords: top, left, bottom, right, and center

Example


  background-position: top left
  

The best way to see this at work is to use the playground below:

  • HTML
  • CSS (SCSS)
  • Output
css
output

Change the background-position value to use a combination of the ...