Printer troubleshooting technician providing live chat help

Joe B.

Expert ★★★★★ 27,853 satisfied customers

Specialities: Confluence Cloud/Data Center, PDF export layout, headers/footers, PDF stylesheet CSS, space export vs single-page export

Confluence PDF export cuts headings — header/footer missing, PDF stylesheet, @page margins, clean export mode

Technician avatar Technician
Let’s fix Confluence PDF export cutting or hiding headers/headings. A few details:
• Confluence Cloud or Data Center?
• Are you using Export to PDF from the page (single-page export) or a Space PDF export?
• What’s missing: the page title/H1, running header/footer, or the first content heading (H2–H4)?
• Any large tables, images, or macros near the top that could push content outside the @page margin on A4/Letter?
Customer
Confluence Cloud. Single-page PDF export. The page title shows, but the first H2 heading is clipped and the header we set in PDF layout doesn’t appear. There’s also a wide table right after the title.
Technician avatar Technician
Got it. In single-page export, Cloud treats the title as H1 in the PDF. Headings below it are demoted visually and can clash with top margins. Also, HTML headers/footers from the PDF Layout page don’t apply to single-page export — you must use PDF stylesheet CSS for running headers/footers. A wide table or big image at the top can push the first heading out of the printable area, so it looks “cut.” We’ll switch to a clean export mode (minimal CSS), add @page margins, and move the wide table below the intro.
Customer
Where do I add that CSS? And what should the stylesheet include to keep headings and headers?
Technician avatar Technician
Step 1 — Add a minimal PDF stylesheet (“clean mode”)
Cloud: Space settings → Look and feel → PDF export → PDF stylesheet.
Paste a minimal CSS that protects headings and prints a running header/footer:
• @page { margin: 18mm 15mm 20mm; } (give H1/H2 room).
• Ensure headings aren’t clipped: h1, h2 { page-break-after: avoid; } and h2 { margin-top: 10mm; }.
• Running header/footer via pseudo-elements (Cloud supports stylesheet-based headers/footers for single-page export).
This “clean mode” reduces theme/UI styles that cause overlaps and preserves page title + first heading.
Customer
Our header/footer HTML from the PDF Layout doesn’t show in single-page export. Is that expected?
Technician avatar Technician
Yes. In single-page PDF export, the PDF Layout (HTML header/footer) isn’t applied. Use the PDF stylesheet to add running headers/footers and to control margins/typography. If you need full title-page + header/footer HTML, use a Space PDF export instead, or keep single-page export but implement headers via CSS only.
Customer
The first H2 is still close to the top edge. We also have a 3-column wide table under the title. Could that be the cause?
Technician avatar Technician
Likely. Wide tables and large images can push headings outside the printable area or force awkward breaks. Do this:
• Insert a short intro paragraph above any wide table so the first H2 isn’t immediately after the title.
• Resize images within tables so the total width fits A4/Letter (roughly ≤600–650px for portrait).
• In the stylesheet, allow tables to shrink: table { width: 100%; table-layout: fixed; } and img { max-width: 100%; height: auto; }.
• Avoid macros that render oversized blocks at the top; place them after the first heading.
Customer
We also need a running header with space name + page title and a footer with page numbers. Possible with CSS?
Technician avatar Technician
Step 2 — Add running header/footer in the PDF stylesheet
Cloud supports using the stylesheet field to create single-page export headers/footers. Add rules like:
• @page { @top-center { content: "Space – " counter(page, decimal) ""; } } (example content — adjust to your needs).
• @page { @bottom-right { content: "Page " counter(page); } }.
Keep margins generous so the first H2 isn’t clipped. Test on both A4 and Letter if your audience is mixed.
Customer
Will Space export behave differently? We sometimes need a title page and a table of contents.
Technician avatar Technician
Use Space PDF export when you need a title page, TOC, and HTML-based header/footer from the PDF Layout. For fast one-off exports, single-page + stylesheet is simpler. If headers/footers ever go missing after an update, re-check the exporter version and re-apply the PDF customizations.
Customer
After adding your CSS and moving the table, the H2 prints fine and headers/footers show. Any other pitfalls?
Technician avatar Technician
A few more tips for a reliable clean export mode:
• Avoid putting a panel/macro as the very first block — leave a small intro above it.
• Keep tables narrow; break very wide content into two tables or use landscape pages for those sections.
• Prevent orphan headings: h2, h3 { page-break-inside: avoid; } and h2 + p { page-break-before: avoid; }.
• Test with and without big images near the top; compress oversized images to avoid scaling glitches in the exporter.
Customer
Perfect. The PDF looks clean now, with headings intact and header/footer on every page. Thanks!
Technician avatar Technician
Summary: When Confluence PDF export cuts headers, use a minimal PDF stylesheet to set @page margins, avoid heading clipping, and create running header/footer. Move wide tables/images away from the title area and let tables scale to page width. For title pages/TOC, switch to Space PDF export. Want help tailoring the CSS? Open the chat.

Quick answer: the accepted fix

Accepted fix when Confluence PDF export cuts headings or hides headers: add a clean PDF stylesheet with generous @page margins, avoid page-breaks after H1/H2, and implement running header/footer via the stylesheet. Move wide tables/images below the intro and let them scale to 100% width.


Why Confluence cuts headers (margins, demoted headings & wide content)

Single-page export treats the page title as H1. If the first H2 follows immediately and a wide table/image sits near the top, the renderer can place it outside the top margin. A minimal PDF stylesheet with safe margins and page-break rules plus moving wide content below the intro keeps headers intact.

How to verify clean mode works

Export the same page twice: first without the stylesheet, then with the clean PDF stylesheet. Check that the page title, first H2, and the running header/footer render consistently. Test on A4 and Letter, and with a second page containing wide tables to confirm scaling and page breaks behave.

Confluence PDF export — quick troubleshooting tips

Most “header cut off” issues are margin + wide-content interactions and layout vs stylesheet differences.

Quick path: add @page margins and heading break rules in the PDF stylesheet → move wide tables/images below the intro → use stylesheet-based running header/footer for single-page export, or switch to Space PDF export for title page/HTML layout needs.

Disclaimer: This information is AI-generated and intended for general guidance only. For advice specific to your environment, please consult a verified expert on Whizz-Tech before making decisions.


Getting Started Is Easy

Ask for help, 24/7

Members enjoy round-the-clock access to 12,000+ verified Experts, including tech support, mechanics, vets, and more.

Expert will respond in minutes

We match you with an Expert who specializes in your situation. Talk, text, or chat — whichever you prefer.

Save time & money

No scheduling hassles or expensive consults. Membership can save you significant time and money each month.

FAQ

Why do my headers/footers not show in single-page PDF export?

Because single-page export ignores PDF Layout HTML headers/footers. Use the PDF stylesheet to add running header/footer, or use a Space PDF export for HTML layout.

How do I stop headings from being cut off?

Add a clean PDF stylesheet with generous @page margins and avoid page-breaks after H1/H2. Move wide tables/images below the intro and allow them to scale to page width.

Can I keep wide tables from breaking the layout?

Yes. Resize images inside tables, set table { width:100%; table-layout:fixed; }, and img { max-width:100%; }. Consider landscape sections only where necessary.

When should I use Space PDF export instead?

Use Space PDF export when you need a title page, TOC, or HTML-based header/footer. For quick single-page exports, use stylesheet-based headers/footers.

Sources

Matt Verified Icon
Matt ● replies in < 1 min
Technician Expert
⭐⭐⭐⭐⭐ Trusted by 27,000+ customers
Avatar
Alex · Expert's Assistant