How To Improve Form Submissions Performance

Overview

Form performance depends on several factors, including your WordPress setup, theme, and plugin versions. You can significantly improve how quickly forms submit and load by reducing form complexity, leveraging built-in performance features, and using add-ons designed for background processing.

This guide covers the most effective strategies for optimizing forms.

Updates

Make sure your site is using the latest versions of WordPress, the theme, and all plugins. See The Importance of Updates.

It’s also important to keep the packages on the server hosting the site up to date. Older versions of PHP, cURL, and OpenSSL can be slow and insecure.

Number of Fields

Breaking up a large form into two or more smaller forms is one of the most efficient ways to improve form performance. This can have the following benefits:

  • Smaller forms are easier for form administrators to maintain.
  • Forms with fewer fields are easier to use and less intimidating for end users.
  • The number of fields to validate is reduced.
  • There will be fewer calculations and conditional logic to evaluate.
  • Fewer fields to process during merge tag and add-on feed processing.

Add-ons that can help with this include:

  • Bulk Actions, by JetSloth, enables bulk management of fields.
  • Easy Passthrough, by Gravity Wiz, can be used to securely pass values between forms without exposing them in the confirmation query string.
  • Gravity Flow and the Form Connector extension can be used to capture additional values later in a workflow. For more details, see the Optimize initial form submission page of the Gravity Flow documentation.
  • Nested Forms, by Gravity Wiz, adds a new field type, called a Nested Form field, which allows you to embed a “child” form into a “parent” form. This child form is used to collect child entries and attach them to the parent entry on submission. The child entries are displayed in a clean, compact table on the parent form, where they can be viewed, edited, or deleted.

Page Fields

When considering how Page fields can be used to break up forms into smaller sections, it’s worth remembering the following:

  • Only the fields on the current page are validated when using the Next button.
  • Validation is not performed when returning to the previous page.
  • All fields on all pages are validated when the form is submitted.
  • Pages and fields hidden by conditional logic are not validated.

Paging performance for some forms can be improved with Page Transitions from Gravity Wiz. This add-on can prevent the submission of individual pages, so that server-side validation occurs only when the form is submitted from the last page.

Conditional Logic

Evaluating conditional logic can be time-consuming for forms with many fields. This time increases exponentially if your form uses nested logic, which is not officially supported and can lead to unexpected results. Therefore, avoid nested logic.

When the form has no nested logic, you can also improve performance by reducing the number of fields using conditional logic.

Instead of configuring the same rules on multiple fields that are grouped together, configure them on Page or Section fields.

Note: All fields located after a Section field, up to the next Section or Page field, are displayed or hidden with the Section field.

If this doesn’t help, consider the solutions from the Number of Fields above.

File Uploads

The standard File Upload field, which uses the browser’s default file input to upload a single file, can impact form submission performance. This is because the browser only starts the upload when the user submits the form. The larger the file, the longer the user will have to wait for the submission to complete.

You can improve performance by using a File Upload field with the Multi-File Upload feature enabled in the field settings. This will use Ajax to upload the file as soon as the user selects it.

Note: You can limit the Multi-File Upload field to allow only one file by configuring the Maximum Number of Files setting in the field settings.

No Duplicates

Try to limit the number of fields where the “No Duplicates” setting is enabled. When enabled, field validation queries the database to ensure the submitted value hasn’t already been used by an existing entry for that field.

Since each submission triggers these lookups, enabling the setting on many fields can noticeably impact form submission performance.

Integrations

Some add-ons can process their feeds in the background, so they don’t slow down form submission completion. For more details, see Add-On Support for Background Feed Processing.

Alternatively, Gravity Flow can be used to schedule the feed processing of compatible add-ons for after the form submission has completed. A list of supported add-ons is available on the Integration with Gravity Forms Add-Ons page of the Gravity Flow documentation.

If you are using Gravity PDF, you can turn on background processing to stop PDF generation from affecting form submission when notifications are sent.

Post Creation

We recommend using the Advanced Post Creation Add-On instead of the built-in legacy post fields. Its feeds can be processed in the background, so it doesn’t block the submission.

The Gravity Flow Advanced Post Creation Add-On integration can trigger feeds after submission has completed.

Notifications

Background processing of notifications allows the user to see the confirmation more quickly by moving notification sending to a separate request. It is enabled by default (for new installations, since v2.10.0) and can be toggled on or off on the Forms > Settings page. It can also be enabled or disabled using the gform_is_asynchronous_notifications_enabled filter.

Gravity PDF, by Blue Liquid Designs, includes built-in support for background processing of notifications that include PDFs. It can be enabled on the Forms > Settings > PDF page.

The following add-ons can be used to delay form submission notifications, schedule notifications, send reminder notifications, create drip-style marketing campaigns, and more.

Troubleshooting Performance

Refer to the Troubleshooting Form Submission Performance article for more information.