Almost every website with a form eventually gets spam: SEO pitches, fake inquiries, gibberish and sometimes malicious links. Most of it comes from automated bots, though some comes from people paid to submit forms. A layered approach stops the bulk without making real customers solve puzzles.
Layer 1: Honeypot fields
A honeypot is a hidden field that real people never see or fill in. Bots, which fill in every field, take the bait. Any submission with the honeypot filled is rejected. It's simple, invisible and surprisingly effective against basic bots.
Layer 2: Timing checks
Real people take at least a few seconds to fill out a form. Bots often submit instantly. Rejecting submissions that arrive too quickly after the page loads catches many automated attempts.
Layer 3: Invisible challenges
Services like Cloudflare Turnstile and Google reCAPTCHA v3 check whether the visitor behaves like a human, usually without asking them to do anything. Turnstile is privacy-friendly and lightweight. reCAPTCHA is widely used but involves Google's tracking, which may matter for your privacy policy and consent setup.
Avoid old-style puzzle CAPTCHAs (identifying traffic lights or typing distorted text) where possible. They frustrate real people and create accessibility barriers.
Layer 4: Validation
- Require a properly formatted email address
- Check phone numbers are plausible
- Set reasonable length limits on fields
- Reject submissions containing many links, which is a strong spam signal for most contact forms
Layer 5: Rate limits
Limit how many submissions can come from the same source in a short time. This stops bots from flooding your form.
Layer 6: Server-side filtering
Spam filters can score submissions based on content, known spam patterns and blocklists, and route suspicious ones to a separate folder instead of your main inbox. Review that folder occasionally so real messages aren't lost.
Protect your email reputation
If your form sends automatic replies, spammers can abuse it to send emails to random addresses through your domain. Make sure confirmations only go out after spam checks pass, and keep the content of auto-replies simple. Proper email authentication helps too. See SPF, DKIM and DMARC.
Handling human spam
Some spam comes from real people submitting sales pitches. Tactics that help:
- A short note on the form: "No sales or SEO pitches, please"
- A required dropdown for the reason for contact, which lets you filter or route pitches separately
- Filtering common phrases
Don't overdo it
Every barrier you add can also stop a real customer. Test your form regularly on a phone to make sure it's still quick and easy. See contact forms that get filled out.
Monitor results
Keep an eye on how much spam gets through and whether real leads are being blocked. If spam suddenly spikes, add a layer. If real inquiries drop unexpectedly, check that your protections aren't too strict.
We build forms with layered, invisible spam protection, and our hosting and care plans keep it tuned over time.
