It seems like your code isn't completely incorrect
However, it might be more appropriate to use the body tag instead of html.
Reasons for using body tag:
By utilizing the body tag, you have the ability to place overlays on top of the body element. For example, you could add a grid-like background to the body with a shaded effect on the sides. Both methods are valid, depending on the desired outcome of the project.
If you want to ensure that your background fills the entire page without repeating, then it may be necessary to resort to using the html tag. However, in this scenario, using the repeat property achieves the same result.
View SO response: credits to attronics
Critique of the 'mistake' mentioned:
If your images are stored in a separate folder from your HTML page (which is generally recommended),
you should employ ..
as a relative path to your CSS file.
Failure to include ..
would mean that the image search pathway begins within the same folder as the HTML page.
body{
background-image:url(../images/background-grid.jpg);
background-repeat:repeat;
}
Here's a resource providing some CSS Basics. Note: the source credibility was not verified.