The download buttons don’t work in my embedded document library

If your document library works perfectly on its own page, but the Download (and sometimes Preview) buttons do nothing once you embed it on another website, this article explains why and what to do about it.

What’s happening

Some website platforms load embedded content inside a sandboxed iframe - a locked-down container that the web browser deliberately prevents from doing certain things, including downloading files. When your document library is placed inside one of these sandboxes, the browser silently blocks the download, so the button appears to do nothing.

Preview can be affected too: by default the preview opens in a new browser tab, and the same sandbox also blocks new tabs from opening.

This is a restriction imposed by the hosting platform and enforced by the browser - it isn’t a fault in Document Library Pro. The identical library downloads perfectly on its own URL, and on any platform that doesn’t sandbox embeds.

Wix is the most common example: both of Wix’s embed options (“Embed HTML/Code” and “Embed a Site”) wrap your library in a sandbox that doesn’t permit downloads.

How to confirm this is the cause

Please check this first, because if the symptoms are different it may be a separate issue that we can fix for you:

  1. Open the library’s direct URL. Copy the address from your embed code (for example https://your-library.documentlibrary.app/?dlp_embed=1) and open it in a new browser tab. Click Download. If it downloads fine there but not when embedded, the embedding sandbox is the cause.
  2. Check the browser console (optional, technical). On the embedded page, open your browser’s developer console. A message such as “Download is disallowed. The frame… is sandboxed and the ‘allow-downloads’ permission is not set” or ERR_BLOCKED_BY_CLIENT confirms it.

If the file also fails to download from the direct URL, this is not the sandbox issue - please contact support and we’ll help you get to the bottom of it.

How to fix it

Wix

Install and use the Document Library Pro Wix app rather than pasting an embed code. The app adds your library as a native Wix element that isn’t sandboxed, so downloads and preview work normally. If you’ve pasted the embed code and are seeing this problem, please contact support and we’ll help you switch over.

Self-hosted WordPress, Webflow, Framer, or plain HTML sites

These don’t sandbox embeds, so the standard embed code works, downloads included. If you’re seeing the problem on one of these, it’s something else - please contact support.

Other website builders (Squarespace, Notion, and similar)

If the platform offers an official Document Library Pro app or integration, use that. If it only offers a generic “embed code” box and sandboxes it, downloads can’t be switched on from our side - but you can still let visitors view your documents (see below).

View-only option (works even inside a sandbox)

If downloads can’t be enabled on your platform, you can still let visitors open and read documents in a viewer on the page. Simply turn off the download button in your library settings and leave the preview button on. Inside a sandbox, the preview automatically opens each document in a viewer on the page (rather than a new tab), so it works even where downloads don’t.

This works for PDFs and images. Word and Excel files can’t be displayed in a browser this way, so a view-only setup suits libraries made up of PDFs and images. If you’d like a hand setting this up, contact support.

Still stuck?

Get in touch via support with your platform name and the page URL, and we’ll advise the best option for your particular setup.

Articoli correlati

Pronto a raccogliere i tuoi documenti in una libreria con ricerca?

Configura la tua prima libreria in pochi minuti - come plugin WordPress, incorporata su qualsiasi sito o come libreria ospitata tutta tua.

Inizia gratis

14 giorni gratis Annulla quando vuoi