Squarespace has no native PDF search — but you can add a fully functional document search widget in about 15 minutes using a Code Block. Here's exactly how.
Sparks Simple Team
14 February 2026
Squarespace is an excellent website builder for small businesses and professional services firms. It looks great out of the box, it's easy to maintain, and it handles most content types well.
PDF documents are the exception. Squarespace lets you upload PDFs and link to them, but its built-in search function searches page content only — not the text inside your PDF files. A visitor who types "annual leave policy" or "mortgage checklist" into your Squarespace search will get zero results, even if you have PDFs that contain exactly that information.
The workarounds people reach for — Google Drive embeds, Dropbox links, iFrame hacks — all have significant drawbacks. Google Drive opens documents in a full browser tab. Dropbox requires visitors to have an account. iFrame solutions are slow, look mismatched, and break on mobile.
There's a cleaner solution: embedding a dedicated PDF search widget using Squarespace's native Code Block feature.
You do not need to know how to code. You will be pasting one line of HTML, which Squarespace handles without any technical knowledge.
Sign up for a Sparks Simple account and create your first widget. Give it a descriptive name — "Client Resources," "HR Policies," "Service Guides" — whatever matches your use case.
Upload your PDF files. The system reads the full text of each document and makes it searchable. Most PDFs are indexed within a minute. Once a document shows a "Searchable" badge, it's ready. You can upload as many documents as your plan allows, and you can always add more later.
While you're in the widget settings, customise the appearance to match your Squarespace site: set the primary colour to your brand colour, adjust the placeholder text ("Search our documents…" or whatever feels natural), and choose whether to show document names alongside search results.
When you're happy with the configuration, navigate to the Embed tab and copy the script tag. It will look something like this:
<script src="https://cdn.sparkssimple.com/widget.js" data-widget="abc123"></script>
That single line is all you need.
Log in to your Squarespace account and navigate to the page where you want the search widget to appear. This is typically your Resources page, Documents page, or Client Centre — wherever visitors would expect to find your documents.
Click Edit to enter the page editor. Click the + button to add a new content block, then select Code from the block types (you may need to scroll down to find it, or search for "Code").
A code editor will appear. Delete any placeholder text that Squarespace puts in by default, then paste your embed code into the editor. Click Apply or Save.
You should now see a preview of the search widget directly in the Squarespace editor. If you see a placeholder or a message saying code blocks aren't rendered in the editor, don't worry — click Done and then Save to publish, then visit your live page to test it.
Visit your published Squarespace page and type a word or phrase that appears in one of your PDFs. You should see results appear within a second or two, showing the matching document name and the relevant excerpt.
Test on your phone as well. The widget is designed to be responsive and should look clean on mobile without any additional configuration.
The Code block is available on Squarespace Business and Commerce plans. If you're on a Personal plan, you may need to upgrade. Squarespace's plan comparison page lists which blocks are available on each tier.
Check that your PDFs have finished indexing in the Sparks Simple dashboard. The "Searchable" badge confirms they're ready. If a document shows "Processing" or "Not indexed," give it a few more minutes and try again.
Return to your Sparks Simple widget settings and adjust the colour and styling options. You can set the exact hex colour code to match your Squarespace theme's primary colour.
If you want the widget to appear on multiple pages, you can also add the embed code via Squarespace's Settings → Advanced → Code Injection → Footer section. This injects the script across your entire site. You'd still use a Code Block on each specific page to place the visible widget — but loading the script globally can improve performance if you plan to use the widget in multiple locations.
Once you've completed these steps, your Squarespace site has something it previously couldn't offer: genuine full-text search across all your PDF documents. Visitors can type questions in plain English and get answers from within your files — no downloading, no scrolling, no calling the office.
For professional services firms, this is often the single highest-impact improvement you can make to your website without touching the design.
Ready to get started?
Start your free 14-day trial — no credit card required. Upload your PDFs, embed a search widget, done.
Start free trial →