I’ve seen this question a lot, in particular in regards to whether Webflow can achieve this with Logic + the CMS. Unfortunately there are still a few significant limitations remaining that make it unsuitable for this use case.
The best approach I’ve found so far is to pair Webflow with automation like Make.com and AirTable or Google Sheets to store your registrations.
All of the magic is in that Make automation.
Receive the event registration form submission
Store the details in AirTable or Google Sheets, so you have a centralized registrant list for all of your events, that can be accessed by your client
Count the number of registrants for event X ( X being the same event as whatever registrant you’ve just added )
Get the associated CMS Event Item, which will contain a “max registrants field”
Do the calc with your two values; max - current = remaining
Update the CMS Event item with remaining, so this can be displayed
This approach has a bunch of advantages including better PII data security, and ease of accessibility. It’s also much more internally-consistent than just trying to increment and decrement a number field.
It also opens the door to a more robust solution where your client can directly add/update/delete registrants directly from AirTable or Google Sheets. In that case you’ll want additional triggers and automations that will re-calculate and re-update your CMS-stored events when the central list is updated.
I have one additional question: now I have to set up Make per event. As I have multiple events (and frequently add more) I wonder if I can set up this once for all events? Do you have a hack for this?
Now you can tell it any CMS item id you want. You’ll have to do this by passing that up in the form submission.
Unfortunately Webflow doesn’t expose that to you. The best way to overcome that is by adding a new field to your CMS, something like “item id” and adding that events auto-generated item id to it.
Now it’s available in an embed element and you may add it to your form: