Documentation / Embedding
Your workbook, inside your website.
Embed a spreadsheet with charts and multiple sheets. Choose an editable copy or a clean viewing surface.
Start with an iframe
- Open your workbook in Hammer Sheets.
- Click Share / Embed in the workbook toolbar. If the toolbar is collapsed, expand Workbook tools first. The current workbook and its latest edits become a snapshot link automatically. Small snapshots stay in the link; larger ones require consent, password and sign-in for encrypted storage.
- Open Embed options and edit mode, tabs, gridlines, headings, starting worksheet (from the current workbook’s visible sheets) and zoom. The iframe code updates automatically. Copy it into a website that permits iframes.
This example shows a public demo in view mode, without editor controls:
<iframe
src="https://sheets.hammerlabs.ai/embed?mode=view&url=https%3A%2F%2Fsheets.hammerlabs.ai%2Fsales-demo.xlsx"
title="Sales dashboard"
width="100%" height="640"
loading="lazy" referrerpolicy="no-referrer"
sandbox="allow-scripts allow-same-origin allow-downloads allow-popups allow-popups-to-escape-sandbox"
></iframe>Preview the view-mode example ↗
Use /embed for iframe content. The home page and /grid block framing. Your website must permit Hammer Sheets in its Content Security Policy frame-src directive.
Choose how it appears
Both /grid and /embed accept these query parameters. Add them after ?, separate them with &, and place them before any # fragment. In HTML attributes, write & instead of &.
| Parameter | Effect | Default |
|---|---|---|
mode=view | Hide toolbar, ribbon, formula bar and other editor controls; disable editing. Use mode=edit for editing. | Edit |
sheet=Sales%20Records | Start on an exact visible worksheet name. URL-encode the name. | Workbook’s active sheet |
zoom=90 | Initial zoom percentage; integer from 10 to 400. | Workbook setting |
tabs=0 | Hide worksheet tabs in view mode. A horizontal scrollbar remains. | Tabs visible |
gridlines=0 | Hide gridlines; 1 shows them. | Workbook setting |
headings=0 | Hide row numbers and column letters; 1 shows them. | Workbook setting |
Boolean options also accept true and false. Unknown parameters and invalid zoom or boolean values are ignored. An unknown or hidden sheet name leaves the active sheet unchanged. Zoom, headings and gridline overrides apply across worksheets.
/embed?mode=view&zoom=90&tabs=0&gridlines=0&headings=0#xlsx=…View mode keeps scrolling, touch panning, zoom and optional sheet navigation. Typing, paste, resizing and object edits are disabled. Without view mode, visitors can edit and download their own copy; changes never write back to the original source.
Share a link or embed the same snapshot
Small workbooks get an anonymous inline link immediately, without an upload or account. Copy the link to share with anyone, or copy the iframe code to embed it. Choose Add password / protected link for encrypted storage with a 30-day expiry. Large workbooks require this protected flow. Storage consent, creator sign-in and a password are required before upload; recipients do not need an account. Send the password separately.
Open the workbook in Hammer Sheets and click Share / Embed. The dialog creates a fresh snapshot and converts its link to /embed, preserving the fragment. The source field is read-only and tied to your current workbook.
For example, customize your current link as /grid?mode=view&zoom=90#xlsx=…, then copy the automatically updated embed code. The Advanced controls apply options to the iframe URL automatically, including for direct XLSX sources. Leave fields blank or choose Keep setting to preserve the existing link or workbook defaults.
The embed shows a snapshot including your latest edits at the time you click Share / Embed. Reopen Share / Embed after further edits to create a fresh snapshot. Protected links still require their password and expire. Fragment payloads and decryption keys are not sent in the HTTP request to Hammer Sheets.
Let browsers fetch your XLSX
Direct workbook URLs must use HTTPS. The source server must allow cross-origin GET requests from https://sheets.hammerlabs.ai. For public files, it can return:
Access-Control-Allow-Origin: *Files are fetched directly by the visitor’s browser, with credentials omitted and no referrer. Hammer Sheets does not proxy files. A URL that works in a browser tab may still fail here if its server does not allow CORS. Inline workbook links do not need a separate source fetch.
For local testing, the source must allow your local origin or *. CORS controls fetching; iframe permissions are separate. If an embed is blocked, check your CMS’s iframe rules and your website’s frame-src policy.
Understand what you share
View mode is a presentation preference, not an access control. Anyone who can load the workbook can access its data and remove mode=view to edit their own copy.
All worksheets, including hidden sheets, remain in the workbook. Hiding tabs does not restrict data access. Anyone with access to the embedding page can recover its source URL or inline payload. Do not include private access tokens in workbook URLs.
Embedded pages do not restore local drafts or account sessions. Cloud account and sharing controls are unavailable inside the embed. Browser policies may restrict downloads or graphics capabilities. Keep your original XLSX: features unsupported by GridCraft may not survive an export.