Protect your Vtiger CRM form from bots
In short: To stop spam on a Vtiger CRM webform, copy its code from Settings › Automation › Webforms (the Get form code icon), run it through the SpamKill Setup Wizard and paste the protected code on your page. SpamKill checks every submission without a CAPTCHA and real enquiries still become Vtiger leads. It takes about 10 minutes.
Bots are filling your Vtiger webform with fake leads. Protect it with SpamKill and real enquiries keep arriving in Vtiger as leads, with every field you collect. One tip first: give the webform a Return Url, or visitors see a bare line of code from Vtiger after they submit.
- About 10 min
- 6 steps
- Copy and paste one snippet
Last verified on Vtiger One Professional (Webforms, Get form code) with the SpamKill Setup Wizard
What changes, and what doesn't
- Enquiries still arrive in Vtiger as leads
- Your webform's fields and Return Url
- Vtiger's own checks on required fields
- Every submission is checked before it reaches Vtiger
- No CAPTCHA for your visitors
- Undo it anytime by putting your old form code back
Before you start
Have these ready so nothing stops you halfway.
- A SpamKill accountNo account yet? Start a free trial.
- Vtiger admin accessYou need to open Settings › Automation › Webforms in Vtiger.
- Access to your page's HTMLYou'll paste HTML into an HTML or code block in your site editor.
Quick setup
For returning users. Each line links to its full step.
- In Vtiger, open Settings › Automation › Webforms › Add Webform, choose Leads, set a Return Url, add your fields and click Save. Step 1
- On the webform's page, click the </> icon (Get form code), then Copy to clipboard. Step 2
- In the SpamKill Console, open Setup Wizard, click No to the WordPress question and paste the code. Step 3
- Click Generate Protected Code, check the email field is email, then click Yes, protect my form. Step 4
- Copy the protected code, paste it where the form should go, publish the page, then click Next. Step 5
- Submit [email protected] and expect an error, then submit a real enquiry and check Leads. Step 6
Create a Leads webform
Where: VtigerSettingsAutomationWebforms
In Vtiger, open Settings, then Automation › Webforms, and click Add Webform. Name it, set Primary Module to Leads (1) and put your thank-you page in Return Url (2). Under Webform Fields, add the fields you want (3) and tick Mandatory for Primary Email (4). Click Save.
You should see: Your webform's page, with its fields and Return Url.
Already have a Vtiger webform?
Use it: open it from Webforms and go on to step 2. If it has no Return Url, click the pencil icon and add one.
Copy the form code
Where: VtigerWebformsYour webform
On your webform's page, click the </> icon at the top right (Get form code). In the panel that opens, click Copy to clipboard (1). Copy all of it, including the script at the end.
You should see: The webform code on your clipboard.
Paste it into the Setup Wizard
Where: SpamKill ConsoleSetup Wizard
In the SpamKill Console, click Setup Wizard in the sidebar. If your site isn't on WordPress, click No under Is your website developed in WordPress?. Paste the code into the box (1).
You should see: Tips under the box, then Generate Protected Code.
Generate the protected code
Where: SpamKill ConsoleSetup Wizard
Click Generate Protected Code. SpamKill asks you to check the email field: it should be email (1). Click Yes, protect my form (2).
You should see: Replace the existing code with this code on your website, above your protected code.
Put the code on your page
Where: Your website editor
Copy the protected code. Open your contact page in your website editor and paste the code where the form should go, replacing any Vtiger webform code. Save and publish the page. Then click Next in the wizard.
You should see: Your page shows the webform's fields and a Submit button.
Does your site style the form by field name?
SpamKill renames the fields, and the wizard lists the old and new names. Update any CSS or scripts that point at the old names.
Test it twice
Open your page in a private window. Submit the form with [email protected] (1). Then submit it again with your own details. You land on your Return Url, and the enquiry appears under Leads (2) with its company and message (3).
The first try shows That email address doesn't look right.
The second try appears under Leads, with every field you filled in.
Back in the wizard, click Both Tests Passed.
You should see: Your thank-you page after the second try.
Your Vtiger CRM form is protected
- Bots are stopped before they reach Vtiger CRM.
- Real leads arrive exactly as before, with no extra steps for them.
- Every block is logged in your SpamKill dashboard.
Something not working?
Find what you're seeing.
Visitors see {"success":true,"result":"ok"} after submitting
That's Vtiger's reply when the webform has no Return Url. In Vtiger, open the webform, click the pencil icon, add your thank-you page under Return Url and save. You don't need to change the code on your page.
A real visitor was told their email doesn't look right
SpamKill checks for missing @ symbols, extra spaces and common typos. The visitor can click Go back to the form, fix the address and send again.
I added fields to the webform later
Copy the new code from Get form code, run it through the wizard again and replace the code on your page.
Changed your mind? Undo in under a minute
- Open the page in your website editor.
- Delete the SpamKill code and paste your original Vtiger webform code back.
- Save and publish the page. Your form is back to how it was.
Thanks! Glad your form is protected.
Sorry about that. Tell us which step tripped you up and we'll fix the guide.
Stuck? We'll set it up with you.
Free setup help for every plan. Send us a message and we'll walk through your Vtiger CRM form with you.
Get setup help