Embed PDF in Squarespace Website: Code Block, Free Options, and Mobile Display
Put a PDF on your Squarespace site so visitors can read it without leaving the page. This tutorial walks through the code block method, free options like Google Drive, responsive iframe code for phones, and a flipbook alternative that feels like a real publication.
You uploaded a beautiful PDF, pasted a link into your Squarespace page, and now visitors have to click away, wait for a download, and hope they come back. That is a leaky funnel. The better move is to embed the PDF directly in the page so people read it right where they already are. This tutorial shows three ways to do it: a Code Block, a free hosted viewer, and a flipbook made with Flipbooks AI that turns a flat file into a page-turning publication. You will also get responsive code so the result looks right on a phone.
Pick the Right Squarespace Plan First
Before you touch any code, check what your plan allows. This single detail causes most of the "why can't I find the Code Block?" questions.
Code Block vs Embed Block
Squarespace gives you two ways to place outside content on a page:
Embed Block: Paste a URL or a snippet from a supported service. Simple, but limited to what Squarespace can recognize.
Code Block: Paste raw HTML, including an <iframe>. This is the flexible option, and the one you want for PDFs.
⚠️ Code Blocks and code injection are generally tied to higher Squarespace plans. If you only see the Embed Block, check your plan under billing before you spend an hour searching the block menu.
Quick Comparison Table
Method
Squarespace Block
Cost
Mobile Result
Best For
Google Drive iframe
Code Block
Free
Decent, scrolls inside frame
One-off documents
Direct PDF iframe
Code Block
Free
Inconsistent on iPhone
Desktop-heavy audiences
Download button
Button Block
Free
Opens in browser viewer
Contracts, forms
Flipbook embed
Code Block
Free tier and paid plans
Responsive, swipe to turn
Catalogs, menus, brochures
Method One: The Code Block Embed
This is the classic route. You host the PDF somewhere public, then wrap its address in an iframe.
Get a Public PDF Address
Your iframe needs a URL that any visitor can open without logging in. You have three common choices:
Upload the file to Squarespace file storage and copy its link.
Share it from Google Drive or Dropbox with public viewing turned on.
Host it on your own server or a storage bucket.
💡 Name the file with lowercase words and no spaces, such as spring-catalog.pdf. Clean names avoid broken links when characters get encoded.
Paste the iframe Snippet
Open the page, click an insertion point, choose Code, and make sure the mode is set to HTML with the Display Source option off. Then paste this:
Replace the src value with your own address. Save, then preview the page. On a desktop browser, you should see the PDF inside the frame with its own scroll bar.
Set the Height Properly
The height value decides how much of the document is visible. A fixed 800 pixels works on laptops but looks cramped on large monitors and wasteful on phones. That is why the next sections matter.
Screen
Suggested Height
Why
Desktop
800 to 1000 px
Shows a full page without scrolling the frame
Tablet
700 px
Leaves room for the page header
Phone
Use the responsive wrapper
A fixed height clips pages
Free Options That Work Today
You do not need a paid tool to get a PDF on screen. You just need to accept some trade-offs.
Google Drive Preview
This is the most popular free route.
Upload your PDF to Google Drive.
Right click it, choose Share, and set access to Anyone with the link as Viewer.
Copy the link. It looks like https://drive.google.com/file/d/FILE_ID/view.
Change the ending from /view to /preview.
Paste it into an iframe inside a Squarespace Code Block.
The upside is zero cost. The downside is a small Drive toolbar in the corner, and visitors who hit the pop-out icon land on a Google page instead of yours.
Dropbox and Direct Links
Dropbox links work if you swap dl=0 for raw=1 at the end of the shared URL. Some browsers then display the PDF inline, others trigger a download. Test in Chrome, Safari, and Firefox before you publish.
A Simple Download Button
Sometimes embedding is overkill. A legal form or a one-page price sheet may be better as a Button Block linked to the file. Visitors get the PDF in their native viewer, which is often the best reading experience for dense documents.
✅ Use embeds for content you want people to browse. Use buttons for files people want to save or print.
Desktop is easy. Phones are where raw PDF embeds fall apart.
Why Native Embeds Break on Phones
iOS Safari often shows only the first page of an embedded PDF as a static image, with no way to scroll through the rest. Some Android browsers refuse to render PDFs in iframes and show a download prompt instead. Squarespace itself is responsive, but a fixed-height iframe does not care about your site's layout.
Responsive Wrapper Code
Wrap the iframe in a container that holds an aspect ratio. A US Letter page is about 129 percent as tall as it is wide, so use that as the padding value:
For landscape documents like slide decks, change padding-top to about 56 percent.
Mobile Checklist
Test on a real iPhone and a real Android phone, not only the browser's device mode.
Keep pages readable at arm's length: body text at 11 points or larger in the source PDF.
Compress images before exporting so the file loads on mobile data.
Add a plain download link under the embed as a fallback.
Mobile Problem
Likely Cause
Fix
Only page one shows
iOS iframe limitation
Use a Drive preview or a flipbook
Gray box, no content
Browser blocks inline PDF
Add a fallback link below
Tiny unreadable text
Fixed iframe width
Use the responsive wrapper
Slow loading
Large file size
Compress images, split long files
Why a Flipbook Beats a Raw PDF
A PDF is a print format. It was never designed for a scrolling, swiping, tapping website. A flipbook converts the same file into a web-native viewer with page-turn motion, zoom, and a layout that adapts to any screen.
For Squarespace users this solves the three biggest headaches at once:
Mobile: The viewer reflows and supports swipe gestures.
Branding: You choose colors and logo, so the embed feels like part of your site.
Measurement: Paid plans add analytics so you can see which pages people actually read.
Who Benefits Most
Photographers who want a portfolio that feels like a printed book. Try the Photography Portfolio tool.
Upload your PDF. Use the PDF to Flipbook Converter. Drag the file in, and each page becomes a flippable spread.
Customize the look. Add your logo, pick brand colors, choose a background, and set the page-turn effect. You can also add video, audio, and clickable links to pages.
Check the preview. Flip through on desktop, then open it on your phone. The layout adjusts automatically.
Open the share panel. Choose Embed and copy the iframe snippet. You can also copy a direct link or add password protection for private content.
Paste into Squarespace. Add a Code Block, paste the snippet, and save. Wrap it in the responsive container from the mobile section if you want a custom ratio.
Publish and test. Load the live page on two phones and one desktop.
💡 Flipbooks AI never adds a watermark to your publication. Your visitors see your brand and nothing else.
Compare everything on the pricing page before you choose.
Real Examples You Can Copy
A Restaurant Menu That Updates Weekly
A neighborhood bistro keeps its menu as a PDF exported from a design tool. When the chef changes dishes, the owner re-uploads the file to the same flipbook, and the Squarespace page updates without touching the embed code. Diners on phones swipe through courses instead of pinching and zooming a tiny PDF.
A Photographer's Portfolio
A wedding photographer exports a 24-page PDF of recent work. As a flipbook, it opens like a printed album, which matches the emotional tone of the business. The embed sits on the Services page, and a button below it links to the booking form.
A Property Packet for Buyers
An agent shares floor plans, neighborhood notes, and pricing in one document. With password protection on, only invited buyers can view it, and the agent can see which pages got the most attention on a Professional plan.
Fixing Common Embed Problems
The Embed Shows Blank
Nine times out of ten the URL is not public. Open it in a private browser window. If it asks you to log in, fix the sharing permissions first.
The Code Block Strips Your Code
Squarespace only runs scripts and iframes if the block is set to HTML and Display Source is off. If you see raw code on the live page, that setting is the culprit.
The Page Loads Slowly
Large PDFs drag. Compress images, remove unused pages, and add loading="lazy" to the iframe so it loads only when a visitor scrolls near it.
Symptom
Check This First
Raw code visible on the page
Display Source toggle
"Refused to connect" message
The host blocks iframes, switch hosts
Embed works on desktop only
Add the responsive wrapper
Old version still showing
Clear cache, republish the page
⚠️ If a host blocks iframes through security headers, no amount of code on the Squarespace side will fix it. Move the file to a host that allows embedding.
Choose Your Method and Publish
Here is a simple way to decide:
Need it free and fast? Use a Google Drive preview inside a Code Block.
Need visitors to save or print? Use a Button Block with a direct link.
Need it to look polished on every device? Build a flipbook.
Ready to try the third option? Get started for free on Flipbooks AI, convert your PDF in minutes, and paste one snippet into your Squarespace page. Browse all flipbook tools to find a template that fits your catalog, menu, or portfolio, or compare plans when you are ready to add analytics and lead capture.