Home » Knowledge Base » Control Panel » How to Embed PDF in WordPress

How to Embed PDF in WordPress

Maintenance

If you’ve written an ebook for the users of your website, chances are you may also need to know how to embed PDF in WordPress.

Of course, there are way more reasons to want to embed a pdf in your website, than the one mentioned above. You may want to promote your ebook by embedding a few sample pages, or there is a report that you want to share with your audience.

Whatever your reasons are, you’ll need to perform a few steps to embed the file directly for the users to see.

Bear with me, it is easy. Really easy.

 

Upload PDF to WordPress

To be able to embed a PDF file in your WordPress-based website, you need to know how to upload it to the website.

Uploading a PDF file is a task that you already should know how to achieve. It goes the same way as when you want to upload media to a post in WordPress. Still, for the sake of comfort, let’s go through the process.

Once you enter the WordPress Admin Panel and see the familiar interface, you need to direct the mouse to the upper left corner, where the Media button is located.

Once you hover it, you can either click it directly or click Library or Add New.

Of course, Add New is the button that if chosen will bring you to the closest to the file uploading interface, but the mentioned button is present on the Library page, which will load whether you click Library or Media.

 

 

I feel more comfortable clicking directly on the first option which will bring me closer to the desired result. Thus, in the image below, you’ll see the page that will appear before you, if you decided to click on the Media or the Library button.

And by choosing that option, you’ll need to click the Add New button on the already loaded page.

On the image below the latest mentioned button is already clicked.

 

 

For this tutorial, I’ve chosen to upload a PDF file that is shared freely by Google. It is called ‘Our progress through 2016’. The report could be found here.

Now that the PDF is uploaded to the website, it is time to embed it.

 

How to Embed PDF in WordPress

If the PDF that you want to embed in your WordPress website is publicly available (as mine) and you know the exact URL to find it, you can always use the <iframe> </iframe> HTML tag, to, in a way, embed it, so it is viewable and usable directly through your website.

Yet, doing so will definitely lead to possible issues, when there is a problem with the service, where the file was originally uploaded, or their website gets discontinued.

To prevent that from happening, or if you have access to the file only locally on your computer, you’ll need to upload the PDF to your WordPress, which we explained in the previous step.

When your file is successfully uploaded, what you need to do is to install a plugin.

The plugin that I trust most is the PDF Embedder.

It is simple, works nicely, and gives you a few very nice to have options. Changing the maximal Width and Height, for example. Which could prove extremely valuable, if your website has a wider or narrower design.

When you install and activate the plugin it already works. You can, if you want, enter the settings page of the PDF Embedder plugin, which you’ll find under Settings on the sidebar menu of your admin panel.

 

 

The beauty of the plugins is that it is the simplest way to embed a PDF in a WordPress website.

What you need to do now that the plugin is installed and activated, is to go to the post, where you want to embed the file or Add a new post, and add the pdf that you want, the same way, you would with a photo or video.

On the top of the WYSIWYG click Add media and you’ll see the familiar option window.

 

 

Choose the pdf file, you want to show to your users, and click Insert into post.

Once you get back to the WYSIWYG, you’ll see something like this:

 

 

Write the content that you want (if you need any) around the embedded PDF, and click publish.

And you’ll see an interactive PDF Viewer directly in your post.

Remember, that if you need, you can tune the width and height of the viewer, so it fits perfectly with your design. You can as well align the embedded pdf – left, right, and to the center, so it looks even more nicely.

This is what you may see when you insert the PDF file in your blog post(or page).

 

 

And this is how to embed a PDF in WordPress.

Hope you’ve chosen the right WordPress Hosting.

 

Read more articles on file Embedding in WordPress:

Was this post helpful?

i

Relevant tags:

Create your WordPress website today!

Connect

Editor’s picks:

Gutenberg Tutorial: How to Move Blocks in WordPress

What you need to know: The WordPress Block Editor allows you to move blocks up and down the document structure in order to rearrange the content contained within those blocks. The most popular way of moving blocks is by dragging a block from one position and dropping...

Gutenberg Tutorial: Deleting a Block in WordPress

What you need to know: You can delete a block in WordPress by selecting it and pressing the Delete key on your keyboard. Alternatively, you can press the three-dot button in the Contextual Toolbar to access the Remove block option. Lastly, it is also possible to...

Gutenberg Tutorial: Using Block Patterns in WordPress

What you need to know: A block pattern in WordPress is a group of two or more regular WordPress blocks. These blocks come in a sensible layout that you wouldn’t need to modify in most cases. Instead, you just need to add your own content to the block pattern. You can...

Gutenberg Tutorial: Using WordPress Reusable Blocks

What you need to know: Gutenberg features reusable blocks that allow you to quickly insert the same content with one click. You can mark any block or block pattern as reusable. You can find your reusable block collection in the WordPress Block Library. Have you ever...



Create your WordPress website today!


Start now