Glossary
Honeypot field
A honeypot field is an input hidden from people but present in the HTML, so any submission that fills it is treated as automated.
Definition
A honeypot is a trap that costs real visitors nothing. The site adds an extra input to a form, for example website or phone2, and hides it with CSS or by moving it off screen. People never see the field, so they leave it empty. Simple spam bots parse the HTML, find every input, and fill each one with something plausible. When the server receives a form where the hidden field has a value, it silently discards the submission or flags the sender.
Honeypots are popular because they are invisible, need no third party, and do not hurt accessibility when built correctly. Many content management systems and form plugins include one by default, often alongside a time check that rejects forms submitted within a second or two of loading.
How sites hide them
- A CSS class that sets
display: noneorvisibility: hidden. - Absolute positioning far off screen, such as
left: -9999px. - Zero size, zero opacity, or a parent container that hides it.
tabindex="-1"andautocomplete="off"so keyboard users and password managers skip it.- A label like "Leave this field empty" for the rare screen reader that reaches it.
Note that type="hidden" inputs are usually not honeypots. Those carry values the site wants back, such as CSRF tokens, and should be submitted unchanged.
How scripts trip them
The common mistakes are filling every text input found in a form, auto-generating values for unknown fields, and building the request body from a list of all input names. Form autofill libraries and some RPA recorders do the same. A related trap is speed: posting a form the instant the page arrives can fail a time based check even when every field is right.
How to avoid them
Fill only the fields a person would see and use. In a browser, check visibility before typing:
# Selenium (Python): fill only inputs a visitor could actually see
from selenium.webdriver.common.by import By
for field in driver.find_elements(By.CSS_SELECTOR, "form#signup input"):
name = field.get_attribute("name")
if not field.is_displayed() or name not in wanted:
continue # skip hidden traps and fields we do not need
field.clear()
field.send_keys(wanted[name])
With an HTTP client, copy the request a real submission sends: the visible fields with your values, hidden inputs with the values the page provided, and every other field empty exactly as the browser sent it. Leave a short, natural pause between loading the form and posting it.
Honeypots and CAPTCHAs together
Sites often stack a honeypot with a CAPTCHA. The honeypot catches the cheapest bots for free, and the CAPTCHA handles the rest. That means a solved token is not the whole story: a form with a valid g-recaptcha-response can still be thrown away because a trap field was filled. When a submission fails without any error message, compare your request with a manual one field by field; the difference is often a honeypot.
For site owners
A honeypot works best with a meaningful name, a reliable hiding method that also excludes it from tab order and autofill, and a silent rejection that does not tell bots what went wrong. It is a low-cost first layer, not a replacement for rate limiting or a CAPTCHA on high-value forms.
Why this matters for allowed automation
Teams that test their own forms or submit public data through approved flows still meet honeypots. Writing scripts that act like a careful person, filling only visible fields and pausing realistically, makes those jobs reliable and keeps them clearly distinct from spam. The guide on scraping without getting blocked lists more habits of the same kind.
Common questions
Is every hidden input a honeypot?
No. Inputs with type="hidden" usually carry CSRF tokens or state the site needs back, and you should submit them unchanged.
How can I spot a honeypot quickly?
Look for text inputs hidden by CSS, positioned off screen or labelled to be left empty, often with tabindex="-1".
Will the site tell me I hit a honeypot?
Usually not. Most sites drop the submission silently or show a generic success page.
Can a honeypot block a request that had a valid CAPTCHA token?
Yes. The two checks are independent, so a filled trap field can sink an otherwise correct submission.
Do time checks count as honeypots?
They are a related technique: forms posted too quickly after loading are treated as automated.
Keep reading
- Scraping without getting blockedA blocking-free scraping checklist: settle these before the first request, watch these during a run, review these afterward.
- g-recaptcha-responseThe hidden textarea that carries a reCAPTCHA token to the server, and how to fill it with a solved answer.
- CAPTCHAWhat a CAPTCHA is, the five families you meet in practice, and why site owners put them in front of forms.
- How should scrapers handle login pages?Log in once with your own account, keep the session cookies, refresh them only when they expire, and pace requests.