The background-size CSS property specifies the size of the background images. The size of the image can be fully constrained or only partially in order to preserve its intrinsic ratio.


background-size: 50%
background-size: 3em
background-size: 12px
background-size: auto

        <title>CSS Tutorials</title>
            .bar {
                width: 50px;
                height: 100px;
                background-image: url(myimage.png);
                background-size: 25px 50px;
                background-size: 50% 50%;
        <div class="exampleone">
            first Div
        <div class="exampletwo">
            Second Div
        <div class="examplethree">
            THird Div