How to Easily Embed a PDF in WordPress

How to Easily Embed a PDF in WordPress

82 / 100 SEO Score

If you want to share a PDF on your WordPress site, like a product catalog, eBook, form, or case study, you don’t have to make visitors download it and open it separately.

Instead, you can embed the PDF right inside your posts or pages. This makes your content more interactive, user-friendly, and professional.

In this post, you’ll learn simple ways to embed a PDF in WordPress without any technical hassle.

Let’s get started.

1 Why Embed a PDF in WordPress

When you embed a PDF in WordPress, you make your site easier to use and more professional. Instead of forcing visitors to download files, they can view your content directly on the page.

Here’s how it helps you:

  • Better user experience: Readers access information instantly without extra steps.
  • Consistent branding: Your PDFs blend smoothly with your site’s design.
  • Practical examples: Share product catalogs on product pages or course materials on class pages.
  • Less clutter: Visitors don’t have to deal with unnecessary downloads.
  • SEO benefits: Search engines can index your embedded content, improving visibility.

2 Methods to Embed a PDF in WordPress

Let us now discuss the various methods to embed a PDF into your WordPress site.

2.1 Embed a PDF in WordPress Without a Plugin

The simplest way to embed a PDF in WordPress is by using the File block in the Gutenberg editor.

To add a PDF using this method, navigate to your post where you wish to add a PDF file, add a new block by clicking the + sign, and select the File block, as shown below.

Embed a PDF using File block

Click the Media Library button if your PDF is already in the WordPress media library. From there, you can easily select the PDF you wish to embed.

Upload PDF file

If the PDF hasn’t been uploaded yet, click on Upload and proceed to choose the file directly from your computer.

Select the PDF file you wish to insert and click on the Select button, as shown below.

select pdf

Gutenberg will automatically handle the embedding process once you’ve selected the PDF file.

PDF file inserted

Furthermore, Gutenberg provides a range of customization options to refine the appearance and functionality of the embedded PDF.

You can directly adjust settings such as alignment, size, and linking preferences within the editor. The File block in Gutenberg allows for effortless resizing, enabling you to control the dimensions of the embedded PDF to align appropriately with the overall design of the content.

PDF File settings

Additionally, linking options allow you to decide whether the embedded PDF should be linked to the media file or an attachment page.

By default, WordPress displays a Download icon in the toolbar and a button beneath the PDF. If you enable the Show download button option in the Settings tab, it will appear at the bottom of the PDF file. Your website visitors can simply click on it to download the PDF file automatically.

Download PDF file

Once you’re happy with the changes, click the Publish/Save button to save your changes. You can then visit your site and see the PDF added to your site.

PDF file added

2.2 Embed a PDF Using a Plugin

WordPress offers a variety of plugins designed to enhance the functionality of embedding PDFs. Among these, the EmbedPress plugin stands out as a versatile solution for easy PDF integration.

At first, you’ll have to install and activate the EmbedPress plugin on your WordPress website.

Refer to our dedicated tutorial on installing and activating the plugin in WordPress.

Once the plugin is installed and activated, navigate to the post-editing screen and search for the EmbedPress PDF block, as shown below.

Insert EmbedPress block

Next, click the Media Library option to add your PDF from the Media Library.

Click the Media Library option

Choose the PDF file and click the Select button to add it to your post.

Choose the PDF file

Your PDF will be added to your post within no time.

PDF added using EmbedPress plugin

You’ll find Document Controls in the Settings tab, offering various options like Presentation mode, Add text, Properties, Rotation, and more. This tab also allows you to specify the PDF’s shareability and other settings.

EmbedPress settings

Once you’ve modified the PDF settings to your preferences, just click the Save/Publish button to make it live on your site.

It’s worth noting that the EmbedPress plugin offers broader customization possibilities compared to the default WordPress File block.

Moreover, the EmbedPress plugin integrates with the Elementor plugin, facilitating easy embedding of PDFs into your Elementor-powered pages.

2.3 Embed a PDF in WordPress Using Google Drive

To embed a PDF using Google Drive, begin by uploading the PDF document to your Google Drive account.

Once uploaded, right-click on the PDF file, select the Share option, and set the visibility to Anyone with the link.

Change the access

This ensures that the PDF is accessible for embedding.

Next, click again on the three dots in your PDF preview and select Open in new window option.

Select Open in new window option

Once the PDF opens in a new window, click on the three vertical dots in the upper right corner and select Embed item.

Select Embed item

Google Drive will generate an HTML code snippet.

Copy the code snippet

Copy this code and navigate to the WordPress post or page where you want to embed the PDF.

Add a Custom HTML block in the Gutenberg editor and paste the code, as shown below.

Paste the code in Gutenberg editor

In the Classic editor, simply paste the code in the text editor, as shown below.

Paste the code in Classic editor

The embedded PDF will now be displayed upon publishing or updating the post/page.

3 Conclusion

Embedding PDFs in WordPress is a simple way to make your site more useful and engaging. You can choose the built-in Gutenberg editor for a quick solution or use a plugin for more advanced features; it all depends on what works best for your content and your audience.

By embedding PDFs, you keep your site professional, improve the user experience, and make your documents easier to access.

Start experimenting with the method that fits your needs, and you’ll quickly see how easy it is to share PDFs on your WordPress site.

Have you been able to embed your PDF files in WordPress? If so, let us know by tweeting @rankmathseo.

Email Icon

Don’t Miss Any Future Post!

Sign up today for Exclusive SEO Articles