Strapi project resets on heroku every couple of hours (dyno restarts)

By default, Strapi uses SQLite (file-based) as its database. So when the dyno restarts, the file goes back to its original state at the time of deployment. Sounds like that’s your scenario.

To solve it, you should migrate to another database such as Postgres. Heroku has a Postgres add-on with a free plan. To set up Postgres for your Strapi instance, check the section “Using Heroku Postgres Addon as Database” on this blog post: Deploy a Strapi API on Heroku in 5 min

1 Like