No upload, 100% local, no account

Add header & footer to PDF

Type text in any of the six slots (header left/center/right, footer left/center/right). Use {page}, {total} and {date} tokens. Everything happens in your browser, your file never leaves your device.

How Add PDF Header & Footer works

Add PDF Header and Footer stamps custom text into the top and bottom margin of every page in a PDF. You can include the tokens {page}, {total} and {date} in your template, and the tool replaces them per page with the current page number, the total page count, and today's date. pdf-lib draws the text directly onto each page inside your browser, and the document stays on your machine the entire time.

This makes the tool useful for a range of stamping tasks: adding a document title to the header, a confidentiality notice to the footer, running page references, or today's date for version tracking. Because the tokens are resolved per page, one template produces correctly numbered output across the whole document. Font size and margin distance from the page edge are configurable so the stamps fit into the available margin space without overlapping the existing content.

How to use Add PDF Header & Footer, step by step

  1. Load your PDF into the tool.
  2. Type your header text in the top field, using {page}, {total} or {date} tokens where you want dynamic values.
  3. Type your footer text in the bottom field in the same way.
  4. Adjust font size and margin distance to match your page layout.
  5. Click apply and download the stamped PDF.

Common use cases

  • Add a document title in the header and a confidentiality notice in the footer for every page of a report.
  • Stamp "Page {page} of {total}" in the footer of a submitted thesis that requires visible page numbers.
  • Add the current date to the header of a contract draft to track which version was printed or shared.
  • Mark every page of a batch of invoices with your company name in the header for professional presentation.

Frequently asked questions

What are the {page}, {total} and {date} tokens?

They are placeholders replaced per page when the stamp is applied. {page} becomes the page number, {total} becomes the total number of pages in the document, and {date} becomes today's date. You can use them alone or combine them with fixed text, for example "Confidential - Page {page} of {total}".

Is there a difference between this tool and the Add page numbers tool?

Add page numbers is focused on just the numeric page label and offers more positioning and format options for that single element. Header and Footer is the right choice when you need arbitrary text in the margins, such as titles, references or notices, along with optional page numbers.

Can I choose where on the page the header or footer appears?

You can control the distance from the top or bottom edge of the page. The horizontal position is centred by default. More granular alignment options depend on the current version of the tool.

Does my PDF go through a server when I add headers and footers?

No. pdf-lib processes the file entirely within your browser. The page text is drawn onto each page in local memory, and the resulting PDF is assembled there and offered as a direct download. No copy of your document reaches Sunasty or any other server.

Does the tool affect the existing content of the pages?

The stamp is drawn into the margin area of each page. If your original PDF has content that extends into the margins, there may be overlap. Setting the margin distance appropriately avoids this.

Can I add a header on some pages and skip others?

The tool applies the header and footer to every page uniformly. To stamp only a subset, split the PDF into sections first, apply the stamp to the relevant section, then merge the parts back together.