Default Placeholders in IronPDF
IronPDF ships with built-in placeholders that resolve to dynamic values when a PDF is rendered. Drop them into your HTML content or into the HtmlFragment property of an HtmlHeaderFooter, and the ChromePdfRenderer swaps them for real values at render time.
The available placeholders are:
{date}: current date{time}: current time{page}: current page number{total-pages}: total number of pages{url}: document URL{html-title},{PDF-title},{pdf-title}: document title
Used inside an HtmlHeader, HtmlFooter, or HtmlFragment object, these tokens are interpreted and replaced automatically during PDF generation.
Preventing Placeholder Replacement
Sometimes you want a placeholder to appear as literal text rather than have IronPDF resolve it. To stop the automatic substitution, change the token so the renderer no longer recognizes it.
- Alter the syntax: write something like
{page_}instead of{page}so it no longer matches a known placeholder. - Hide it from the renderer: wrap the text in a non-rendered element, such as an HTML comment or a
spanwithdisplay:none.
Either approach leaves the text untouched in the final output.

