Docs / Contact form guides
Add a contact form to a plain HTML site on Netlify
A plain HTML form on Netlify that emails you, with spam filtered and no captcha.
Add a working contact form to this plain HTML site hosted on Netlify. Create the form by sending POST https://wrenform.com/api/v1/quick-forms with JSON {"email": "YOUR_EMAIL", "framework": "html"} (if you can't make HTTP requests, give me the curl command to run). Put the returned snippet on a /contact page or section, matching the site's style: a label for each field, type="email" on the email field, and keep the _honey field exactly as returned. Show a thank-you message after sending and an error message on failure. Don't add a data-netlify attribute. Add no dependencies, API keys or server code. Then tell me to check my inbox for the Wrenform email and click Confirm, because messages are held until I do.Replace YOUR_EMAIL with the address that should get the messages, and paste. This creates a form without an account: no sign-up, no mail provider, free for 250 submissions a month. Nothing is forwarded until you click Confirm in the email we send, and unconfirmed forms are deleted after 7 days. Prefer the dashboard? Create a form and use the snippet below.
A plain HTML site has no server of its own. The form posts to Wrenform from the visitor's browser, so it works the same on Netlify, any other static host, or your own server.
Steps
- Paste the prompt into your coding tool, or paste the HTML below into
contact.html. - Optional: add a thank-you page and set its full address as the form's Redirect to. See redirects.
- Click Confirm in the email from Wrenform.
- Deploy to Netlify as usual.
Don't add a data-netlify attribute: the form posts straight to Wrenform, not to Netlify's form handling.
Lock the form to your site. A form created this way accepts posts from any site. Once you've confirmed, sign in with the same address and add your published domain under Allowed origins in the form's settings, for example https://example.com.
Or paste the code
<form action="https://wrenform.com/f/YOUR_FORM_ID" method="POST">
<input type="text" name="name" required>
<input type="email" name="email" required>
<textarea name="message" required></textarea>
<input type="text" name="_honey" style="display:none" tabindex="-1" autocomplete="off">
<button type="submit">Send</button>
</form>
<!-- Optional: a timing check against bots, and data-ajax to submit in place -->
<script src="https://wrenform.com/js/v1/form.js" defer></script>Replace YOUR_FORM_ID with the ID from your form's Setup page. The script tag is optional: it adds the timing check.
Spam and email
- The hidden
_honeyfield catches most bots. Keep it in the form, hidden, withautocomplete="off". - A timing check marks submissions sent less than 3 seconds after the form loaded as spam, when the form sends the timing field. The optional script in the HTML snippet adds it; see the timing field. No captcha is needed.
- Each real submission is emailed to you and shown in your dashboard. If a field is missing from the email, check that its input has a
nameand isn't disabled. - Submissions are stored in the EU.
Test it
Deploy a preview, open the contact page and send the form. After confirming, the message is in your inbox and your dashboard. Send one more from your live domain.
Common problems
- The form sends but no email arrives. The address hasn't confirmed yet. Look for the email from Wrenform, also in spam.
403 origin_not_allowed. The page's origin isn't in the form's Allowed origins. Add it, including any preview domain you test from. See errors.- Netlify shows its own form page. Remove
data-netlifyornetlifyfrom the form tag and deploy again. - Anything else. See troubleshooting.
Next steps
- HTML guide: every option for a plain form.
- Prompts for AI builders: the same prompt for other tools.
- Pricing: free for 250 submissions a month, paid plans from €5.