Html Background Image Fit To Screen

css background image size to fit screen
html {
height: 100%
}
body {
background-image:url("../images/myImage.jpg");
background-repeat: no-repeat;
background-size: 100% 100%;
}
how to cover full image in css
body {
background-position: center;
background-repeat: no-repeat;
background-size: cover;
}
html background image fit to screen
body {
background-position: center;
background-repeat: no-repeat;
background-size: contain;
}
make background image full width
html {
height: 100%;
}
body {
color: #999;
background: url('../images/background/main_bg.jpg') no-repeat center center fixed;
font-family: 'Roboto', sans-serif;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
}

Leave a Comment