Export form entries as PDF files from your WordPress forms. You can also attach a PDF of each entry to the email notification.
There are several ways to export entries as a PDF:
Upgrade your WordPress site with powerful, flexible forms.
Download and install
- If you haven't already, install and activate the current version of Formidable Forms Premium on your WordPress site.
- After confirming your Formidable Forms license, go to Formidable → Add-Ons and toggle on the WordPress PDFs plugin.

- This add-on requires the following:
PHP Version 7.1 or higher Extensions DOM extension MBString extension GD extension
From Idea to Reality in Minutes. Build Powerful Forms, Dashboards, Apps and More.
Formidable Forms makes advanced site building simple. Launch forms, directories, dashboards, and custom WordPress apps faster than ever before.
Export entry as PDF
Download a single entry as a PDF from its entry details page.
- Go to Formidable → Forms and edit your form. Then click Entries at the top of the form builder.
- Select the View or Edit link below the selected entry that will take you to the entry details page.
- In the admin sidebar under the Entry Actions section, select the Download as PDF link.

Attach PDF of entry to email
Attach a PDF of the submitted entry to an email notification.
- Go to Formidable → Forms and edit your form. Then go to Settings → Actions & Notifications.
- Click the Send Email action to edit it, or click Send Email in the list of actions at the top to add a new email notification.
- Scroll down to the Attachment section and toggle on Attach PDF of entry to email.

Alternatively, for a more customized PDF, you can use the frm-pdf shortcode (see below) inside the email content.
Insert the shortcode manually
You may insert the following shortcode on a page, post, email notification, or View to show an expiring link to the entry's PDF export.
[frm-pdf]
Parameters
- id: Change the entry ID that holds the value you want to retrieve. When using the shortcode in Email content, On submit message, or View content, the current entry ID will be automatically used.
[frm-pdf id=x]
Replace x with the ID of the entry you want to display. The entry ID is found on the entry details page.
- label: By default, the label is shown as Download PDF. If the label is set to empty (label="") or 0 (label=0), the shortcode will display the URL.
[frm-pdf label="Click to download entry as PDF"]
- output: Set the value to url to show only the PDF URL instead of a link. The label, title, class, html_id, and target parameters are ignored.
[frm-pdf output="url"]
- title: Change the PDF link HTML title attribute. If this is empty, the label attribute will be used.
[frm-pdf title="Entry PDF link"]
- mode: Change how the PDF file is delivered after clicking the link. Set the mode using either mode=view or mode=download. The default mode is view, where the PDF file content is shown in the browser. Use download as the value to automatically download the PDF file.
[frm-pdf mode="download"]
- include_fields: Only include specific fields in the PDF file content. By default, the PDF includes all fields.
[frm-pdf include_fields="10,15"]
- exclude_fields: Exclude specific fields in the PDF file content.
[frm-pdf exclude_fields="10,15"]
- include_extras: By default, page breaks and section headings are used in the shortcode. If admin_only is used, the PDF file also includes fields that the field Visibility setting hides from the current user.
[frm-pdf include_extras="page, section, html, admin_only"]
- class: Add your own CSS class to the PDF link to style it. The class only changes the link. The PDF content always uses your default Formidable style.
[frm-pdf class="class_name_here"]
- html_id: Change the PDF link HTML id attribute. This identifier must be unique across the page.
[frm-pdf html_id="entrypdf"]
- target: Change the PDF link HTML target attribute. By default, the link opens in the same tab. Use target="_blank" to open the PDF link in a new browser tab.
[frm-pdf target="_blank"]
- public: The default value is empty. If the value is set to "0" or empty, only logged-in users who create the entry or have the frm_view_entries capability can view the PDF file.
[frm-pdf public="0"]
If the value is set to "1" or a non-empty value, any user with the link can view the PDF file.
[frm-pdf public="1"]
Note: The public link is valid for up to 4 days. After that, users must return to the page with the link to get a new one.
To give each person a link to their own entry's PDF, add a Formidable PDF item to a Gated Content action and use this shortcode for the item. Then add the action's access link shortcode to a Confirmation or Send Email action. The access link opens the PDF without logging in.
[frm-pdf id=[id]]
- access_code: Gated Content adds this parameter to its PDF links with the person's access code, so you don't need to add it yourself. For users who aren't logged in, a value that isn't a valid access code doesn't open the PDF. It also replaces the code that public="1" adds, so the public link stops working for them.
- paper_size: The default value is set to letter. Accepts paper sizes such as letter, legal, and A4.
[frm-pdf paper_size="letter"]
- orientation: The default value is set to portrait. Accepts portrait or landscape.
[frm-pdf orientation="portrait"]
- source: Show any shortcode. This will show the output of [your-shortcode] in the PDF file.
[frm-pdf source="your-shortcode"]
- your-attr: Any attribute added to the [frm-pdf] shortcode, except action, is passed to the [your-shortcode] shortcode. This will show the output of [your-shortcode your-attr="1" another-attr="Hello"] in the PDF file.
[frm-pdf source="your-shortcode" your-attr="1" another-attr="another"]
- param: Pass a value to the PDF download URL. When passing dynamic parameters to the PDF, it will include the same filters as the View.
[frm-pdf view="10" param="[get param=param_name]"]
Replace 10 with the View ID. Replace param_name with your parameter name.
- show_pagination: Set the value to 1 to include pagination at the bottom of every page, for example, Page 1 of 3.
[frm-pdf show_pagination=1]
Display View in PDF
You may insert the following shortcode to show a View in the PDF file.
[frm-pdf view="x"]
- view: Show the listing page of a View. Using public="1" will let any user view the PDF file.
[frm-pdf view="10" public="1"]
Replace 10 with the View ID.
- id: Show the detail page of a view by using both view and id attributes.
[frm-pdf view="10" id="12" public="1"]
Replace 12 with the ID of the entry that you want to show.
- filename: Set a custom file name. It can be dynamic like filename="{date}-{key}-{25}". Do not include .pdf as a value in the filename attribute.
[frm-pdf view="10" id="12" filename="PDF File" public="1"]
- source: Another way to display a View.
[frm-pdf source="display-frm-data" id="10" public="1"]
Replace 10 with the View ID.
- entry_id: Display a View of the submitted entries.
[frm-pdf source="display-frm-data" id=10 entry_id=363 public=1]
Replace 10 with the View ID and 363 with the entry ID.
- entry: To get the Detail view, replace entry with the value set for the Detail Page slug in the View settings.
[frm-pdf source="display-frm-data" id=10 entry=363 public=1]
Replace 10 with the View ID, 363 with the entry ID, and entry with the detail page slug.
How to create a custom PDF
Design a custom PDF with the Views builder.
- If you haven’t yet, go to Formidable → Forms and click the Add New button to create a new form.
- Go to Formidable → Views and click Add New to create a View. Select a View type, such as Grid, choose your form under Use Entries from Form, and click Create a view. The View controls how the data in your form is displayed in the PDF.
- Using the built-in View Layout builder, you can start designing your layout however you like. Add a field or content to each cell, click Save Layout, and then click Update to save the View.

- Publish the PDF download link and display the Listing View by adding the shortcode. Note: Using public="1" will allow all users to view the PDF file. Learn more about the available shortcode parameters.
- If you publish on a page/post, add a Shortcode or HTML block and insert the shortcode:
[frm-pdf view=10 public=1]
or
[frm-pdf source="display-frm-data" id=10 public=1]
Replace 10 with your View ID.

- If you publish using a Confirmation action, select the Show Message button. Customize the success message by inserting the shortcode:
[frm-pdf view=10 public=1]
or
[frm-pdf source="display-frm-data" id=10 public=1]
Replace 10 with your View ID.

Note: If you are using the view parameter, it will display the Detail Page content for the current entry if it is present.
Import a PDF template
Start your custom PDF from a pre-built PDF template.
- Select from the available pre-built PDF templates and click Use This Template.

- Go to Formidable → Import/Export. Click Choose File, select the downloaded PDF template XML file, and click Upload file and import. It imports all the forms and Views in the template.

- Click Go to imported application to open the PDF application template and customize it. If the template only has a form, click Go to imported form.

Add background to PDF
Personalize your PDFs with a custom background image. You add the image with CSS in the View that builds the PDF.
- Go to Formidable → Applications and install the Certificate Application Template. Type Certificate in the search box, then hover over the Certificate template and click Add.

- In the box that opens, click Install Application. Keep or change the application name and click Install Application again. Learn more in Application Builder.
- Click Open Application. Hover over the Certificate of Completion Grid View and click Edit.

- In the View builder, click the dashed bar above the layout to edit the Before Content section, and click the Code tab. In the
.frm-certificaterule, find the background property:background: center / cover no-repeat url('http://sandbox.formidableforms.com/demos/wp-content/uploads/sites/17/2023/03/certificate-bg.jpg');Replace the URL with the address of the image you want as the background of your PDF. Then, click Update.

- The frm-certificate class is already in the Custom Classes field of the Grid Style Settings. If you prefer to use a different class name, change it in the code in the Before Content section.

Use a custom font in PDF
A custom font gives your PDF a personal touch and a unique, professional look.
- Choose a custom font. We recommend Google Fonts, which offers tons of free, open-source fonts.
- Add a stylesheet link and refer to the font in CSS. For example, we want to use a Parisienne font from Google Fonts.
<link href="https://fonts.googleapis.com/css2?family=Parisienne&display=swap" rel="stylesheet" style="display:none" /> <style>.frm-certificate { font-family: Parisienne,Georgia,'DejaVu serif',serif; color:#3C5C45; font-size:18px; line-height:1.2; text-align:center; }</style>Go to the Before Content section in the View builder, click the Code tab, and insert the code above.

- Add custom class. Insert frm-certificate in the Custom Classes field of the Grid Style Settings. If you prefer to use a different class name, change it in the code you added in the Before Content section.

Add custom PDF to email
Send a custom PDF made with the View builder in an email notification by adding its shortcode to the email message.
- Go to Formidable → Forms and edit your form. Then go to Settings → Actions & Notifications.
- Select and edit the email notification action, or create a new one by clicking Send Email in the list of actions at the top.
- In the Message box, insert the shortcode below to allow any user who has the link to access the PDF file.
[frm-pdf view=10 public=1]
Replace 10 with your View ID.

Note: If you are using the view parameter, it will display the Detail Page content for the current entry if it is present.
Display Detail View in custom PDF
Show the Detail View of a specific entry or the current entry in a custom PDF.
- Create a View with a detail page.
- If you are using the default detail page slug, you can publish the shortcode like this:
- Display the Detail View for a specific entry.
[frm-pdf view=10 id=363 public=1]
Where 10 is the View ID and 363 is the entry ID.
- Display the Detail View for the current entry.
[frm-pdf view=10 id=[id] public=1]
Where 10 is the View ID. Using [id] as the value will dynamically display the current entry.
- Display the Detail View for a specific entry.
- If you have set a custom detail page slug found in your View Advanced Settings, you can publish the shortcode like this:
- Display the Detail Page content for a specific entry with the custom detail page slug.
[frm-pdf source="display-frm-data" id=10 pdf_entry=363 public=1]
Where 10 is the View ID, 363 is the entry ID, and pdf_entry is your custom detail page slug.
- Display the Detail Page content for the current entry with a custom detail page slug.
[frm-pdf source="display-frm-data" id=10 pdf_entry=[id] public=1]
Where 10 is the View ID and pdf_entry is your custom detail page slug. Using [id] as the value will dynamically display the current entry.
- Display the Detail Page content for a specific entry with the custom detail page slug.
Display Listing View in custom PDF
Show a Listing View in a custom PDF for a specific entry or the current entry.
- Create a View for your submitted entries with a Listing View.
- To display the Listing View for a specific entry, use this shortcode.
[frm-pdf source="display-frm-data" id=10 entry_id=363 public=1]
Where 10 is the View ID and 363 is the entry ID.
- To display the Listing View for the current entry, use this shortcode.
[frm-pdf source="display-frm-data" id=10 entry_id=[id] public=1]
Where 10 is the View ID. Using [id] as the value will dynamically display the current entry.
Create anchor links in PDF
Make your PDFs interactive with internal links that let your readers jump to different sections within the PDF.
- Create the anchor link. In the Before Content of your View, switch to the Code tab of the editor and manually create an anchor link in HTML. For example:
<div><a href="#best-wordpress-form-plugins">Best WordPress Form Plugins</a></div>
- Add the ID attribute. Scroll down to the After Content area of the View, where you can add the section you want to link. Locate the HTML tag you want to target, such as <h2>, <div>, or <p>. Add the ID attribute with your anchor’s link slug without the # prefix. For example:
<div id="best-wordpress-form-plugins">Best WordPress Form Plugins</div>
- Save your changes. Preview the View to test the anchor link. With this setup, you can add your main content to the Listing Page content and ensure a page break.
Limitation
Graphs from the [frm-graph] shortcode are not included when you download your entries in PDF format.
Formidable PDFs uses the Dompdf library to convert HTML into a PDF. Dompdf has a few limitations that affect how your PDFs are rendered.
Table rows can't split across pages
A table row must fit entirely on one page. If a row is taller than the space left on the page, Dompdf moves the whole row to the next page, which can leave a gap at the bottom.
Content is placed as it's parsed
Elements are rendered onto whichever page is active when they're read, so you can't reposition content after the fact. Page breaks need to be planned in your layout rather than corrected afterward.
Inline SVG isn't supported
Raw SVG markup won't render. As a workaround, link to an external SVG file, or embed it as a data URI:
$html = '<img src="data:image/svg+xml;base64,' . base64_encode( $svg ) . '">';Flexbox isn't supported
CSS display: flex is ignored. Use tables or floats for multi-column layouts in your PDF.
CSS Grid isn't supported
CSS display: grid is ignored, with the same alternatives as flexbox.
More information about this here: https://github.com/dompdf/dompdf?tab=readme-ov-file#limitations-known-issues
Troubleshooting
You are not allowed to view this file
By default, only a logged-in user who has the frm_view_entries capability or creates the entry can see the PDF file. If you receive this error notice, setting the public parameter value to 1 will permit any user to access the PDF file. [frm-pdf public="1"]
A PDF link is only valid for 4 days. If it is used in emails, the links may be older than 4 days. You can use the frm_pdfs_access_code_max_days hook if you need to extend the lifespan of a PDF link.
Alternating rows displayed in black
If you export a specific entry as a PDF in the form Entries page, you might see solid black bars in the generated PDF's styling. The code snippet below can fix this.
add_filter('frm_pdfs_css',
function( $css ) {
$css .= '
.frm_pdf_tr:nth-child(2n) {
background-color: #fff !important;
}
';
return $css;
}
);Missing styling in downloaded PDF
If you have added styling to your custom PDF, check if any blank lines have been added to your CSS code. WordPress adds <p> tags inside the <style> tag when it finds blank lines in the code, and those tags can keep the CSS from being applied.
To stop these paragraph tags from being added when you publish the custom PDF, include wpautop=0 in the shortcode.
[frm-pdf view=278 wpautop=0 public=1]
Extra blank pages in the PDF
When a custom PDF made from a Grid View has blank pages before, between, or after the entries, a common cause is the View's padding. In the PDF, the Padding from the View's Grid Style Settings is added above and below each entry. The default is 10px on every side.
When an entry already fills most of a page and its content can't split across pages (for example, a table, an image, or a fixed height), this extra space makes it taller than the page. The entry then moves to the next page and leaves a blank page behind.
To remove the blank pages, take out the top and bottom padding:
- Go to Formidable → Views and edit the Grid View you use for the PDF.
- Open Grid Style Settings. Under Padding, set the first slider (top and bottom) to 0. Set the second slider (left and right) to the space you want on the sides, such as 8px.

- Click Update to save your changes.
Then, open the PDF link again to check the result.
If you still see blank pages, make the content of each entry shorter. An entry that nearly fills the page can still leave a blank page without padding. An entry that is taller than one page also adds blank pages and can have part of its content cut off. Learn more in the Limitation section.
A page break at the end of each entry also adds a blank page at the end of the PDF.
Related customizations
Force a page break
Add a page break to a custom PDF so the content after it starts on a new page of the downloaded PDF file.
- Go to Formidable → Global Settings → Custom CSS and insert the following CSS.
.page_break { page-break-after: always; }Then, click Update.
- Go to Formidable → Views and edit the View where you want to force a page break. On the Listing Page tab, click the content of an entry to open the Edit Listing Page Content box. Select the Code tab and add the following HTML where you want the new page to start.
<div class="page_break"></div>
Then, click Update.
The page break repeats with every entry because the Listing Page Content does. With the HTML at the end of the content, each entry starts on a new page. In a Grid View with several cells, each cell opens its own content box, so add the HTML to the last cell. The PDF also ends with a blank page. To start the entries on a new page after a cover page instead, add the HTML at the end of the Before Content section.
- Insert the [frm-pdf view=278 public=1] shortcode to show the download link for the custom PDF. Replace 278 with the View ID.
Styling pagination
If you have enabled pagination in your PDF, you can change the styling by adding custom CSS in your Formidable → Global Settings → Custom CSS page. The CSS below will change the pagination color and position it to the top left:
.frm_pdfs_pagination {
top: 0;
bottom: auto;
text-align: left;
color: blue;
}Attach custom PDF of entry to email
Attach the custom PDF of the submitted entry to the email notification instead of the default entry PDF.
- Activate this code snippet to apply the View you used to generate the custom PDF. Replace the form ID and View ID.
- Go to Formidable → Forms and edit your form. Then go to Settings → Actions & Notifications and open the email notification action.
- Scroll down to the Attachment section and toggle on Attach PDF of entry to email.

Style the entry PDF table
When you export an entry as PDF, the content is built from a fixed set of classes. Target them with the frm_pdfs_css hook to change spacing, borders, or typography.
Here is the markup the export generates:
<div class="frm-pdf-content">
<p>Added on: April 22, 2025 at 8:20 am</p>
<div class="frm_pdf_table">
<div class="frm_pdf_tr">
<div class="frm_pdf_td" colspan="2">
<div class="field-label">First Name</div>
<div class="field-value">Jane</div>
</div><!-- End .frm_pdf_td -->
</div><!-- End .frm_pdf_tr -->
<div class="frm_pdf_tr">
<div class="frm_pdf_td" colspan="2">
<div class="field-label">Email</div>
<div class="field-value">jane@example.com</div>
</div><!-- End .frm_pdf_td -->
</div><!-- End .frm_pdf_tr -->
<div class="frm_pdf_tr">
<div class="frm_pdf_td" colspan="2">
<div class="field-label">Message</div>
<div class="field-value">This is an example message.</div>
</div><!-- End .frm_pdf_td -->
</div><!-- End .frm_pdf_tr -->
</div><!-- End .frm_pdf_table -->
</div>| Class | What it wraps |
|---|---|
.frm-pdf-content |
The whole export, including the submission date paragraph |
.frm_pdf_table |
The table wrapper around all field rows |
.frm_pdf_tr |
One row, which is one field |
.frm_pdf_td |
The cell inside the row |
.field-label |
The field label |
.field-value |
The submitted value |
Change the row height
Row height is driven by content, not by a height property. Setting a height on .frm_pdf_tr only works as a minimum, since Dompdf grows a row to fit its content but will not shrink it. To tighten or loosen rows, adjust the padding on .frm_pdf_td and the spacing on the label and value.
add_filter('frm_pdfs_css',
function( $css ) {
$css .= '
.frm_pdf_td {
padding-top: 2px !important;
padding-bottom: 2px !important;
}
.frm_pdf_td .field-label,
.frm_pdf_td .field-value {
margin: 0 !important;
line-height: 1.2 !important;
}
';
return $css;
}
);Increase the padding and line height values to space the rows out instead.
Related developer hooks
- Include the form title and description in the exported PDF file with the frm_pdfs_export_content hook.
- Add extra content in the exported PDF file with the frm_pdfs_export_content hook.
- Filter the fields used for the exported PDF entry content with the frm_pdfs_fields_for_export hook.
- Filter the PDF entry export file name with the frm_pdfs_export_file_name hook.
- Filter the CSS of the PDF entry export with the frm_pdfs_css hook.
- Filter the default atts of the [frm-pdf] shortcode with the frm_pdfs_default_shortcode_atts hook.
- Filter the output of the [frm-pdf] shortcode with the frm_pdfs_shortcode_output hook.
- Filter the download URL of the [frm-pdf] shortcode with the frm_pdfs_download_url hook.
- Filter the args of FrmProEntriesController::show_entry_shortcode(), which is used in the content of the PDF entry export file with the frm_pdfs_show_args hook.
- Filter the maximum days an access code can expire with the frm_pdfs_access_code_max_days hook.
- Filter the args of the DOMPDF constructor with the frm_pdfs_dompdf_args hook.
- Apply custom font to the PDF entry export (including Hebrew characters) with the frm_pdfs_css hook.
- Add custom class for table view with the frm_views_table_class hook.
- Wrap all grid items inside a custom wrapper or show total of items at the end of a table view with the frm_display_inner_content_before_add_wrapper hook.
- Apply a view for the attached PDF or change the attached PDF file name with the frm_pdfs_email_attachment_args hook.
- Add custom pagination with the frm_pdfs_after_render hook.






















