I'm upgrading a site that has public registration from v3 to v4 (better late than never!) and it's going to take a few days to QA v4 locally to make sure everything works correctly… I'm wondering what's the best way to keep the new user accounts in sync.

Is my only option to disable user registration while performing the upgrade? Or are the user tables self contain enough to update users independently once v4 is ready to go live? If so, how would I go about it?

Any pointer in the right direction much appreciated!

1 Answer 1


I suspect everyone would have slightly different ways of approaching this according to their appetite for risk, but if you're anything like me, I originally didn't realise that re-running the upgrade for a second time with fresh data is actually extremely simple and fast - all you need to do is wire up the old DB with your newly upgraded site and do ./craft up. In other words, assuming you have a deployment process that does that (or a combination of composer install + ./craft migrate/all) it's all handled for you when you deploy your upgraded version. The annoying part compared to pre-project-config days is that it will cause a few seconds of downtime while migrate/all happens, but it may be acceptable enough to do it without deliberately taking the site down.

If those few seconds of downtime are unacceptable to the business, you'd need to find a way to keep the site up but conditionally disable any user-generated content such as registrations and form submissions, then call for an editorial content freeze before doing the upgrade on a separate environment and then switching seamlessly/instantly to that environment - typically with some kind of symlink. See for example: https://nystudio107.com/blog/executing-atomic-deployments

  • Indeed, I didn't realize you could just do ./craft up on an updated site with the older version of DB populated with the latest data. I already went with the second option you mentioned (freeze user-genereated and editorial content) but I'll have to test out the first option locally when I have to update to v.5 (coming out pretty soon it seems…) Thanks!
    – Yann
    Commented Feb 15 at 4:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.