Background Wallpaper Code Html Background Wallpaper

To add a wallpaper image to the website — one that covers the entire page — you have to write some CSS rules for the body element. Here's how: body{ background-image: url('bg-image.jpg'); } In the code above, we're using the background-image property to add an image to the body of the webpage. To add a background image on an HTML element, use the HTML style attribute and the CSS background-image property: Example Add a background image on a HTML element:

Try it Yourself » You can also specify the background image in the