Depending on the browser, there will always be a default 8px margin or padding on either html or body element.
Example as shown below with red arrows:

To remove these so called “slack space”, do the following on your body tag in your CSS stylesheet:
1 2 3 4 | html, body{ margin: 0 auto; padding: 0; } |
This will overwrite the default margin or padding that your browser has set. Now lets see the aftermath:














