Google chrome prints extra page

Use Following Code in css

 @media print {
     html, body {
        border: 1px solid white;
        height: 99%;
        page-break-after: avoid;
        page-break-before: avoid;
     }
}

See The Preview After Adding Css ;

enter image description here


In my case, this fairly heavy-handed solution worked:

@media print {
     html, body {
        height: 99%;
        overflow: hidden;
     }
}

Basically, you can simply force everything after the first page to be hidden. Obviously you want to be pretty sure that you're not losing anything valuable.


I try to print and it was one page, you can try add print break after- before avoid on i.e footer

@media print {
    footer {page-break-after: avoid;}
}