There are two ways to upload an HTML file to Squarespace:
Method 1: Use the Code Block
The Code Block is a versatile Squarespace block that allows you to add custom HTML, CSS, JavaScript, and Flash. It’s perfect for embedding third-party applications or adding custom code.
To add a Code Block:
- Open the page or post editor and click an insert point.
- In the Blocks panel, click Code.
- Click Edit Code.
- Paste your code into the Code Editor and click Apply.
Method 2:
Upload your HTML file as a resource. You can then link to it from anywhere on your site, including the Code Block.
-
In the Home Menu, click Pages, and then click the + icon next to Main Navigation.
-
Click Link, and then enter the URL for your HTML file. We recommend using HTTPS for security purposes.
If you’re using our Domain names feature, you can link to your file using a domain name you’ve set up for your site. Learn more about linking to resources.
-
Click Save & Close.
Linking to your resource from a Code Block
-
Open the page or post editor and click an insert point.
-
In the Blocks panel, click Code.
-
3. Click Edit code.