How to add a header and footer to a PDF
Updated
Contents
To add a header and footer to a PDF, open PDF Header & Footer, add your PDF, type a line in Header text, a line in Footer text, or both, and press Add header & footer. Each line is drawn on every page, and you download the stamped copy.
The footer starts out as Page {n} of {total}, so a plain page count needs no typing at all. The {n}, {total} and {date} buttons beside each field add a field that fills itself in page by page: {n} is the page number, {total} the number of pages in the file, and {date} today's date as your browser writes it.
The PDF is read and rewritten in your browser, so it stays on your device, and there is no account to create. It takes one PDF at a time, up to 100 MB.
Step by step
- 1Open the PDF Header & Footer tool.
- 2Drop your PDF on the panel that says “Drop your PDF here, or browse”, or click it to choose the file. Its name, page count and size appear above the editor.
- 3Type the top line in Header text and the bottom line in Footer text. The {n}, {total} and {date} buttons add that field to the end of the line; leave a field empty to skip that band.
- 4Choose Left, Center or Right under each field. The chip beside the Header and Footer headings shows how page 1 will read.
- 5Press Add header & footer. It works once either field has text.
- 6When the panel reads Header & footer added, press Download PDF. report.pdf is saved as report-header-footer.pdf.
Page numbers, the page count and the date
{n} is each page's position in the file, counting the first page as 1, and {total} is the number of pages the file has, so the default footer reads Page 1 of 12 on the first of twelve pages. Typing {page} and {pages} works the same way.
{date} is filled in once, when you press the button, and written as plain text, so it does not change when the file is opened later. It takes your browser's date format when a font pdf.xyz ships can draw it beside your text; otherwise the same day is written in Latin digits, and failing that as year-month-day. The chip beside each heading shows exactly what will be printed.
What you can change, and what is fixed
You choose the wording, the fields and each band's alignment. The font size, the grey ink and the distance from the edge are fixed, and each band holds one line in one position, so the same band cannot carry text at the left and the right at once.
Every page gets the same lines, the first page included. The text is drawn on top of the page with no background, and nothing is moved to make room, so text already printed near the edge will overlap it, and running the tool twice gives two headers. A page stored sideways still gets its header at the top as you view it, reading level.
Languages and scripts
While everything in both lines fits the Western European character set, it is set in Helvetica. One character outside it moves both lines to a Noto typeface that the page fetches from pdf.xyz's own site and embeds in the file; that request carries nothing from your document. The scripts it can draw are Bengali, Latin, Greek, Cyrillic, Devanagari, Hiragana, Katakana, Kanji, Hangul, and Han.
Arabic and Hebrew text is refused, because each line is laid out left to right and would come out reversed. So is text in a script no shipped font draws, such as Thai or Tamil, and emoji. Both lines share one font, so a header and footer that would need two, such as Japanese above Bengali, are refused too, and the message names the scripts involved.
Common questions
How do I add Page 1 of 10 to the footer?
It is the default. The footer opens as Page {n} of {total}, and the total is the file's own page count. Reword it as you like, for example {n} / {total}, or press Add header & footer as it is.
Can I leave the header off the cover page?
Not with this tool: every page gets the same lines. If what you need on the other pages is a number, Add Page Numbers has a Start on page setting that skips the cover.
Can I change the font, size or colour?
No. The size, the grey ink and the margin are fixed. The typeface follows your characters: Helvetica for Western European text, and an embedded Noto face when a character needs one.
Does my PDF leave my device?
No. It is opened, stamped and saved in your browser tab, up to 100 MB. When your text or the date needs a Noto font, the page fetches the font file from pdf.xyz's own site, and that request carries no part of your document.
Why was my header text refused?
Arabic and Hebrew cannot be laid out right to left yet, scripts such as Thai or Tamil have no shipped font, and emoji are not embedded. A header and footer that need two different fonts are refused together, so put a Japanese header over a footer in Latin letters rather than one in Bengali.
Can I add a header to a password-protected PDF?
Not while it is locked. An encrypted PDF is stopped when it is read, with a message naming its lock and a link to Unlock PDF. That tool removes the lock with a password you know, but it runs on our secure server, so the file leaves your device for that step.