HTML CSS examples for CSS Property:background-color
Set web page background color to black
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> body {<!--from w w w .j a va 2 s .c o m--> background-color: #000000; text-align: center; } #main { width: 1000; height: 600px; background-color: blue; } </style> </head> <body> <div class="body"> <div id="main"> Hi </div> </div> </body> </html>