Swiftype is a third-party service you can use to add a search engine to your site.
Note: Each page can only contain one Swiftype search box. If there are two Swiftype search boxes on a page, neither will work.
Note: For the best search experience, we recommend using our Search Block instead of a third-party service.
The steps in this guide include Code Injection and adding advanced code to the Code Block. These are Premium features available in Business and Commerce plans.
Step 1 - Create a search engine
Log into your Swiftype account and click Create An Engine.
Click Create a search engine > (Standard Web Crawler).
In the Website URL box, enter your built-in Squarespace domain or custom domain. Click Verify.
Enter a name for your search engine in the Engine Name box. Then click Create Engine.
Swiftype will crawl your site and create your search engine, showing the progress along the way.
Step 2 - Copy the code
When the crawling is complete, click the Complete Setup.
On the next screen, click Install Swiftype On Your Website. Copy the Swiftype Install Code. You can use a Code Block or a Code Injection point and Code Block to install the Swiftype search overlay on your site.
Step 3 - Add the code
There are a few ways to add the Swiftype code to your site depending on where you want it to display.
Option 1 : Add Swiftype to all pages
In the Home Menu, click Settings, click Advanced, and then click Code Injection.
In the Header field, paste the code. Click Save.
Note: For further assistance, visit Using Code Injection.
In Swiftype, copy the Search Field code and paste it in a Code Block on the page where you want to display a Swiftype search.
Another approach to the Search Field code to Code Injection. This adds Swiftype search to every page on your site.
Option 2: Add Swiftype to specific pages
To add a Swiftype search overlay to a specific page of your site, choose a page to add your Swiftype search box and open the editor. Click an Insert Point and select Code from the Block Menu.
For more detailed steps, visit Adding blocks with Insert Points.
Paste the code from Swiftype into the Search Field box followed by the code from the Swiftype Install Code box.
Note: This third-party customization falls outside the scope of our support. This means that we’re unable to help further with setup or troubleshooting. Additionally, since this is a code-based solution, we can’t guarantee its functionality or full compatibility with Squarespace. This includes how it functions with our responsive design, particularly its appearance on mobile devices, and if it functions on all templates. Third-party customizations can also cause display issues with future updates to our platform. While we can't help further, there are many resources that can point you in the right direction: