To add a sign-up checkbox to your Contact Form 7 forms, you can add the following “shortcode” to your Contact Form 7 form.

[mc4wp_checkbox "Label text"]

The plugin will automatically replace the shortcode with a sign-up checkbox and render the necessary HTML code for you.

Another option is to include a hidden field like this.

<input type="hidden" name="mc4wp-subscribe" value="1" />

If people submit your Contact Form 7 form with the checkbox checked, the plugin will find the email address and name and subscribe the person to the list(s) selected in MC4WP > Integrations > Contact form 7.

Requiring more list fields

If your selected Mailchimp list requires more fields than just EMAIL, NAME, FNAME, LNAME then you will need to add those fields as well. You can do this by prefixing the name of the CF7 field with mc4wp-. The part after the dash has to match the exact field name in Mailchimp.

Example

[text* mc4wp-FIELDNAME]

For more information, please have a look at the documentation for sending additional Contact Form 7 fields to Mailchimp.

Contact Form 7 Email

To show if the checkbox was checked in the email that is sent by CF7, use the following variable in your email template.

<p>
  Wants to receive newsletter: [mc4wp_checkbox]
</p>