<?xml version="1.0" encoding="utf-8"?>

The background color property

The background color property

You can apply the background-color property to pretty much any element, not just text. Using this property in the <body> tag will set the background color for the entire page.

Remember how HTML elements are similar to boxes? Setting the background color for an element will change the color of its whole box, including the borders.

Top contributors

Olivier Nottebart

Topics

From Lesson

Share

Improve your UX & Product skills with interactive courses that actually work