_cf_sp_hp_email
field name so it can be implemented within seconds.
Setting Up Universal Honeypot (fast, may not be as effective)
Comfyform allows to implement a universal honeypot field using_cf_sp_hp_email
field name. This way, the honeypot protection can be implemented easily in seconds, but it may not be as effective as using your form’s unique honeypot field name. Just add this code to your HTML form:
Setting Up Extremely Effective Honeypot (recommended)
To effectively implement the honeypot technique in your Comfyform, you should utilize the code snippet provided right after your form is created. Alternatively, you can check the honeypot field name in the spam protection settings of your form in dashboard.Keep it seamless, use the provided code upon form creationUpon creating your new form in Comfyform, you’ll receive a code snippet with effective honeypot implementation in mind. Grab the ready-to-go code, customize as desired, and be assured it includes the correct form ID and honeypot field name for immediate use.Create new form
Step 1: Retrieve Your Unique Honeypot Field Name
- Log in to your Comfyform dashboard.
- Navigate to the Forms section and open the form you wish to secure.
- Click on the Security tab.
- Locate the Honeypot settings and click the “Modify” or “Activate” button.
- Copy your Honeypot field name designated for that particular form. You can also rename it and use your own field name, for example if the generated one is a name you’d like to use for real data.
Step 2: Implement the Honeypot in Your HTML Form
Incorporate the honeypot field into your form’s HTML structure as illustrated below, replacingHONEYPOT_FIELD_NAME
with the actual name provided.
Best Practices for Honeypot Implementation
- Styles: Ensure your honeypot field is hidden using
position: absolute; left: -9876px;
on a parent element — this keeps the field invisible to users but accessible and tempting to bots. - Autocomplete: Turn off autocomplete for the honeypot field by setting
autocomplete="nopls"
. Don’t useoff
value because some browsers may ignore it and still fill out the field. - Tabindex: Set
tabindex="-1"
to prevent keyboard navigation users from selecting the field. - Keep the field tempting: By camouflaging the field as a normal one you’ll get better results from the honeypot protection. Don’t omit the label, placeholder and a name containing
email
word.