2

I am thinking of moving from Wordpress to Squarespace but have written a custom plugin for wordpress that regularly updates a news feed. I have looked through the Squarespace documentation and it seems rather restrictive. Is there any way to store database information in Squarespace and run a cron job?

ThatGuy
  • 1,225
  • 10
  • 28

1 Answers1

3

No, you can only add "client-side code" to a Squarespace site, and not "server-side code".

You can't add server-side code

Server-side code is handled by a server, not by a browser, and includes: PHP, Ruby, Ruby on Rails, SQL

So you'd have to find some other service to run your cron job, a separate server, etc. A couple solutions used by Squarespace devs. who also need database functionality is Firebase, or Google Sheets + Apps Script. For example, you'll see a lot of Squarespace users sending their data to Google Sheets, then using Zapier and/or Apps Script to manipulate data and trigger other services. Of course, the endpoint then needs to be accessible via Javascript/AJAX in order to display data on your site.

Brandon
  • 3,572
  • 2
  • 12
  • 27