A WordPress block editor showing a PDF embedded inline inside a published blog post

How to Embed a PDF in WordPress (Plugin vs No-Plugin)

Two reliable ways to embed a PDF in WordPress: a plugin-powered viewer or a simple no-plugin File block and iframe. Steps, a comparison, and troubleshooting.

To embed a PDF in WordPress, upload the file to your Media Library, then either add a PDF viewer plugin and drop in its block or shortcode, or skip the plugin and use the built-in File block (or a one-line iframe) that displays the PDF inline. The plugin route gives a polished in-page reader; the no-plugin route is faster and lighter to maintain.

Both methods take only a few minutes, and the right choice depends on how much you care about the on-page reading experience versus keeping your site lean. Below are the exact steps for each path, an honest comparison of the two, and the most common reason a viewer refuses to show up at all.

Key takeaways

  • Plugin method: best when you want a real in-page reader with zoom, page navigation, and a download button styled to match your theme.
  • No-plugin method: best when you want speed and nothing extra to maintain. The built-in File block or a one-line iframe handles it.
  • Every method starts the same way: upload the PDF to your Media Library and copy its file URL.
  • The most common failure is a blank box, usually from a slow-loading large file, a mixed-content (HTTP/HTTPS) mismatch, or a caching plugin serving a stale page.
  • Large or scanned PDFs load slowly inside any viewer. Trimming or compressing the file first makes a real difference.
  • If you only need the words on the page rather than the document "feel," converting the PDF to HTML often beats embedding it.

Before you start: upload the PDF

No matter which path you choose, the first step is identical. In your WordPress dashboard, go to Media → Add New and upload your PDF. Once it finishes processing, click the file thumbnail and copy the File URL shown in the details panel on the right. You will need that link for almost every method below, so keep it handy.

A quick gut-check before you upload: open the PDF and ask whether it is the leanest version of itself. A 40-page scanned brochure will crawl inside any viewer, and visitors will feel every second of it. If the file is bloated, compress it or split out just the pages you actually need first. A smaller file embeds faster, scrolls more smoothly, and frustrates fewer readers, especially those on phones or slower connections.

It is also worth confirming the file actually opens correctly on your own machine before it goes live. A corrupted or password-protected PDF will look fine in your Media Library but fail silently inside an embed, leaving you chasing a problem that is really in the file itself.

How do I add a PDF to a WordPress page?

Here is the shortest reliable answer, using only what is already built into WordPress. No plugin required.

  1. Open the page or post in the block editor.
  2. Click the + to add a block and choose the File block.
  3. Select your PDF from the Media Library, or upload it on the spot.
  4. WordPress inserts the file with a clickable link and a Copy / Download button automatically.
  5. Open the block settings on the right and turn on Show inline embed if you want the PDF to display inside the page rather than appear only as a link.
  6. Update or publish the page.

That is the genuine no-plugin route, and for most blog posts and resource pages it is all you need. The inline embed leans on the visitor's browser to render the PDF, which is why it tends to "just work" on desktop but can behave differently on some phones. More on that in the troubleshooting section below.

Method 1: Embed a PDF with a plugin

A plugin is the right call when you want the document to feel like part of the page, complete with page navigation, zoom controls, and a styled download button. Popular options include PDF Embedder and EmbedPress, along with similar WordPress PDF viewer plugins. The workflow is nearly identical across all of them.

  1. Go to Plugins → Add New and search for a PDF viewer plugin.
  2. Click Install Now, then Activate.
  3. Open the page or post where you want the document to appear.
  4. Add the plugin's block, or paste its shortcode, for example [pdf-embedder url="https://yoursite.com/wp-content/uploads/2026/06/your-file.pdf"].
  5. Adjust the width, height, and toolbar options in the block or shortcode settings.
  6. Preview the page, confirm the viewer loads, then publish.

The realistic failure mode: plugins that render the PDF with JavaScript can clash with caching, minification, or security plugins. If your viewer shows a spinner forever or a blank frame, a script is almost certainly being blocked or deferred before it can run. Temporarily disabling minification, or excluding the viewer's script from your cache, usually clears it up. Keep two habits in mind: test with one plugin at a time so you know which one works, and remember that every active plugin adds weight to your site, so do not leave three viewers installed once you have picked a winner.

One more practical note: some viewer plugins lock features like custom toolbars, multiple embeds per page, or mobile-optimized rendering behind a paid tier. Check what the free version actually includes before you build a whole resource page around it.

Method 2: Embed a PDF without a plugin

This is the long-tail favorite, how to embed a PDF in WordPress without a plugin, and beyond the File block above you have two clean options.

Option A: A simple iframe

Add a Custom HTML block where you want the document, then paste:

<iframe src="https://yoursite.com/wp-content/uploads/2026/06/your-file.pdf" width="100%" height="800px"></iframe>

Swap in your own file URL. The browser handles the rendering, so there is nothing to install or maintain. Set the height generously (800 pixels is a sensible starting point) so visitors are not squinting through a tiny window. Using width="100%" keeps the embed responsive across screen sizes, though the document inside still relies on the browser's own PDF viewer.

Option B: A styled link with a thumbnail

Sometimes the cleanest way to add a PDF to WordPress is not to embed it at all, but to present a clear, clickable link or button: "Download the 2026 Pricing Guide (PDF, 1.2 MB)." It loads instantly, works on every device, and respects readers on slow connections. Pair it with a small cover image or thumbnail and it looks every bit as intentional as a full embed, without any of the rendering quirks. Including the file size and format in the link text is a small courtesy that sets expectations before anyone clicks.

If you are embedding on platforms beyond WordPress too, the same iframe logic applies elsewhere. Our guide on how to embed a PDF on a website using HTML and Wix walks through those variations in detail.

Plugin vs no-plugin: an honest comparison

FactorPlugin viewerNo-plugin (File block / iframe)
Setup time5–10 min2–3 min
In-page reading experienceRich (zoom, paging, toolbar)Basic, browser-dependent
Site speed impactAdds scripts and weightMinimal
Mobile reliabilityUsually handled by the pluginVaries by phone browser
Styling controlHighLow
MaintenancePlugin updates, possible conflictsNone
SEO of the PDF's textLimitedLimited

When to use the plugin: you are building a flipbook, a portfolio, a magazine-style resource, or any page where the document is the experience and you want it to look identical for every visitor. The richer reader is worth the extra weight when the PDF is the main attraction.

When to skip the plugin: you run a content site, you care about speed and Core Web Vitals, or you simply want readers to grab a file and move on. The File block or a plain link does the job without another moving part to update and troubleshoot.

Neither option is universally better. A law firm publishing a polished case study leans toward the plugin; a busy blog linking to a printable checklist leans toward no plugin. Match the method to what the document is actually for, not to whichever sounds more impressive.

A note on PDFs and SEO

Embedding a PDF, by any method, does not place the document's text into your page content the way a search engine reads it best. The file is essentially a window onto a separate document sitting beside your page, not part of the page itself. If the words inside that PDF matter for ranking, or you want readers to copy, search, and skim them naturally, converting the document into real web content is the stronger play.

Our walkthrough on converting a PDF to HTML for publishing or embedding on a website covers exactly that process. You can also prep, trim, or tidy the source file first in our online PDF editor so the version you publish is clean, lightweight, and free of pages your readers do not need. A clean source file helps every method on this page, embed or convert.

Troubleshooting: the viewer shows a blank box

If your embed publishes but displays nothing, work through these causes in order, from most common to least.

  • The file is too large. Big or scanned PDFs can take many seconds to render and may appear blank while they load. Compress the file or split out only the pages you need, then re-upload.
  • Mixed content (HTTP vs HTTPS). If your site loads over HTTPS but the PDF URL starts with http://, browsers quietly block it for security. Make sure the file URL matches your site's secure https:// protocol.
  • A caching plugin served a stale page. Clear your site cache and your browser cache after publishing the embed, then reload the page in a fresh tab to confirm.
  • A minification or security plugin blocked the viewer's script. Exclude the PDF viewer's JavaScript from minification or script deferral, or temporarily disable those plugins to confirm the conflict before adding an exception.
  • The phone browser will not render inline PDFs. Some mobile browsers refuse to display a PDF inside an iframe and simply show nothing. A clear download link is the dependable fallback for those visitors.

Fix the underlying file and protocol issues first, since they sit behind the majority of blank-box reports. Plugin and caching conflicts are real but less common, so rule out the simple causes before you start disabling things.

FAQ

How do I add a PDF to a WordPress page?

Upload the PDF under Media → Add New, then open your page in the block editor and add a File block pointing to that PDF. WordPress creates a download link automatically, and you can turn on the inline embed option to display the document right on the page. No plugin or code is required for this basic approach.

Can I embed a PDF in WordPress without a plugin?

Yes. The built-in File block embeds a PDF inline with no extra software, and you can also drop a one-line <iframe> into a Custom HTML block pointing at your file's URL. Both rely on the visitor's browser to render the document, so there is nothing to install or maintain over time.

Why isn't my embedded PDF showing up?

The usual culprits are a file too large to load quickly, a mixed-content mismatch where the PDF link uses http on an https site, or a caching plugin serving an old version of the page. Clear your cache, confirm the file URL is secure, and try compressing the PDF before you reload. If a viewer plugin is involved, check whether a minification or security plugin is blocking its script.

Will embedding a PDF help my SEO?

Not much on its own. An embedded PDF behaves like a separate document inside a frame, so its text is not read as native page content. If the words matter for ranking, or you want readers to skim and copy them, converting the PDF to HTML and publishing it as a real page is the better move.

Which is better, a plugin or no plugin?

It depends on the goal. Choose a plugin when you want a rich in-page reader with zoom and page navigation and you are willing to manage updates and the occasional conflict. Choose the no-plugin route when speed, simplicity, and Core Web Vitals matter more than a polished viewer. For most blogs and resource pages, the built-in File block is plenty.

Usama Ramzan
Written byUsama RamzanFounder, Online PDF Edits

Usama Ramzan is the founder of Online PDF Edits, a browser-based PDF editor built to change text, images, and tables in existing PDFs without breaking their fonts, spacing, or multi-page layout. He writes about practical PDF editing, document workflows, and the engineering behind layout-safe editing.

Recommended reading

View all articles →