Print Stylesheet Generator
Build a print stylesheet with page size, margins, hidden chrome and printed link URLs.
Build a print stylesheet
Print stylesheet preview
This mock page shows how the generated print rules change the output. Toggle an option and watch the matching block react straight away.
Read the guide (/guide/) for a longer walkthrough of print CSS.
Figure 1 - chart placeholder
break-inside: avoid
© 2026 ffee · runs locally · no data collected
@page: A4 15mm · links: urls
shown
How to use the Print Stylesheet Generator
- Pick the page size, page margin and base print font size.
- Tick the options to hide navigation and footers, force background colours, print link URLs and avoid breaks in figures.
- Copy the generated stylesheet and paste it at the end of your CSS file.
Features
- Page size and margin rules written as an at-page block
- Options to hide navigation, headers, breadcrumbs and footers
- Printed link URLs and forced background colours
- Break avoidance for figures, images, tables and code blocks
Advertisement
Frequently Asked Questions
Common questions about the free online print stylesheet generator.
It is a set of rules wrapped in a print media query that only apply when a page is sent to a
printer or saved as a PDF file.
Add a print media query and set display to none on your header, navigation and footer
selectors so only the article body is printed.
Use an at-page rule with a size value such as A4 and a margin in millimetres, exactly as the
generator writes it into the output box.
Browsers drop backgrounds to save ink. Force them with print-color-adjust set to exact on the
elements that need their colours.
Add a rule on anchor elements whose after content reads attr href, which prints the
destination address straight after the link text.
Set break-inside to avoid, together with the older page-break-inside property for engines
that still expect the legacy name.
It shows the same rules applied on screen, so you can confirm what is hidden, what is
coloured and which links gain a printed URL.
Yes. The rules use standard print CSS, so they work with plain stylesheets, preprocessors and
component frameworks alike.
Yes. It is completely free, runs locally in your browser and needs no account, no sign-up and
no upload of your own styles.
Last updated: October 10, 2026