Our Top Ranked #1 Web Host for WordPress Hosting
Latest Uptime Stats (Real Records):
Server Response Speed Test Scored A+:
In this post, I’ll show you how to add a consent checkbox in Contact Form 7, since you need to add one for contact forms as well.
This will be pretty easy, since Contact Form 7 has already implemented such a feature.
How to add a consent checkbox in Contact Form 7
In order to add a consent checkbox in Contact Form 7, you have to:
1. Go to Contact -> Contact Forms and select the contact form that you want to edit.
2. Add whatever privacy text you see fit.
3. Click with your mouse cursor at the beginning of the text and then click the acceptance button.
4. A pop-up box will appear with some options, which you can leave as is.
You could change the name, though, if you wish, with something more “friendly”, like
Don’t select the Make this checkbox checked by default option, since it’s against the GDPR rules. You have to let the users give their consent by checking the box.
5. Click the Insert Tag button.
6. After inserting the tag, it will appear at the beginning of the text.
7. This is important! Unlike other Contact Form 7 tags, the
[acceptance] tag has to be closed! You can do that by adding
[/acceptance] at the very end of the text.
Note that the
[acceptance] tag will be required by default!
Adding an error message
If users try to send a message without checking the consent checkbox, no error will appear. Nothing will happen when pressing the submit button. This is a default setting.
If you want an error to display when users try to send a message without checking the box, then you have to add the following code in the Additional Settings tab:
Now you can go and see how is your consent checkbox looking like on your contact form.
That’s a wrap
Hope you liked the post and understood how to add a consent checkbox in Contact Form 7!
If you have any questions or thoughts, drop a comment, contact us or message us on Facebook.
If you want to start your own WordPress blog, or need a website for your business, our WordPress installation and customization service is at your disposal! We also provide WordPress support and maintenance!
You can also purchase a ready-made WordPress website with hosting and support included!