Submission Limits Pro

If you need to set limits on the number of submissions a form may receive or who can submit the form, a few options are available.

Per User Pro

Inside the Validation tab (lock icon) in the form builder, an option exists to allow you to limit the number of times a user can submit the form. Look for this setting:

  • Limit Form Submission Rate
    • Do not limit
    • Logged in Users only (no limit) 3.13+
    • Once per Cookie only
    • Once per IP/Cookie combo
    • Once per logged in Users only 3.13+
    • Once per logged in User or Guest Cookie only 3.13+
    • Once per logged in User or Guest IP/Cookie combo 3.13+

Per Form Pro 3.12+

Freeform includes the ability to set a limit on the maximum number of submissions a form may receive, and the reject any additional ones. You can also include a template-based condition check and display an alternate message without ever presenting the form to the user in the event it's reached it's limit.

The key is applying the submissionLimit parameter to the freeform.form function and feeding it a number value. This could be hardcoded or you could grab this value from somewhere else such as another element or global variable, etc. Here's an example of what that may look like:

{# Replace 'myForm' with your form handle. #}
{% set form = craft.freeform.form("myForm") %}

{# Specify the submission limit here (or grab this value from somewhere else such as another element or global variable, etc) #}
{% set submissionLimit = 50 %}

{# This optional conditional checks if the form has reached its submission limit set above #}
{% if craft.freeform.submissionCount(form) >= submissionLimit %}

    <p class="alert">Submission Limit Reached!</p>

{% else %}

    <p class="notice">
        This form has a limit of {{ submissionLimit }} submissions.
        There are currently {{ craft.freeform.submissionCount(form) }} submissions for this form.
    </p>

    {{ form.render({
        submissionLimit: submissionLimit,
    }) }}

{% endif %}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23

Stop Submissions After Date 3.13+

Inside the Validation tab (lock icon) in the form builder, an option exists to allow you to prevent new submissions of the form after the set date.

Last Updated: 2/13/2022, 10:34:29 AM