How to Embed PDF, Spreadsheet, and others in WordPress Blog Posts


One of our users asked us how they can embed PDFs in their WordPress blog and make it available for others to download as well. In this article, we will show you how you can embed PDFs, Microsoft Word Documents, PowerPoint slides, Excel Spreadsheets, and other elements in your WordPress blog by using a plugin called Google Doc Embedder. Don’t let the name fool you. It does not require you to have a Google Docs account. It simply uses the Google Docs viewer to display all of those files on your blog.

Video Tutorial

Subscribe to WPBeginner

If you don’t like the video or need more instructions, then continue reading.

First thing you need to do is install Google Doc Embedder Plugin. (refer to our step by step guide to installing a WordPress plugin).

Once you have this plugin installed, a new settings panel will be added under Settings » GDE Settings.

Google Docs Embedder Settings Page

You can customize the width. Choose whether you want to show the download links to everyone or just logged in users, and control other options. Once you have done that. Lets come back to the media uploader, and upload a new file (your PDF file or Excel file that you want to display). Then copy the Media File url like its shown in the image below:

WordPress getting the Media File URL

Now open your post editor, and use the shortcode like this:

[gview file=""]

You can override other elements in there such as width= or height= etc. For more Usage Notes refer to the developer’s site.

And you are done. You should now have a PDF attached in your WordPress post with a download link if you have that option selected.

Notice: Many folks confuse the plugin with the name Google Docs. The point of this plugin is to display locally hosted files in the blog not embedding from the Google Docs itself.

Download Google Doc Embedder