Adding custom code

Can I add Flash, JavaScript or HTML to my website?

Yes, you can add Flash or JavaScript to areas of your site that are configured to accept code. You'll need to upload any necessary files (.swf, .xml, javascript library, etc.) within [Website Management > Data and Media > File Storage] and preface all calls to these files with /storage/ within your code.


You can add code to pages and posts on your site by inserting the HTML for your applet into the Raw HTML editing mode, or clicking the filmstrip icon in the WYSIWYG editor. You can also add this within various areas of your template (from the Code Injection area). To add flash as your site header, for example, you can add the code to the Site Banner HTML Override code injection point if you have the Unlimited plan.


Note: Creating/amending the code for this is an advanced modification that requires programming knowledge to complete. Most issues involving adding this to your site are related to incorrectly constructed file structure.

Can I run PHP, SQL, CGI, Java or other server side code within my Squarespace account?

No. Squarespace does not support the uploading and running of server side code. However, you can embed client side scripts that utilize Javascript within your pages and posts. One of the major advantages of Squarespace is that by using the framework provided, you can eliminate the need for integrating, installing, managing, and debugging various scripts if we have provided a page or widget to perform the function you're looking for. We currently have no plans to support server side code in the future, though we may open up an interface to the widget API which will let you embed more complex logic within your pages.

Was this article helpful?
0 out of 0 found this helpful