How to Add a Formspree Form to a Static HTML Website
Updated
To connect a static HTML form to Formspree, point the form's action at your Formspree endpoint (https://formspree.io/f/{form_id}), set method="post", and give each input a name attribute. Formspree receives the submission, validates it, filters spam, emails you, and stores it in your Formspree inbox — no server code on your side. This works for any static host (GitHub Pages, Netlify, plain HTML files) and requires only a Formspree account and a form ID.
What you need before starting
- A Formspree account and a form created in it, which gives you a form ID (the
{form_id}segment in the endpoint). - An HTML page you can edit, hosted anywhere or opened locally.
- No backend, database, or mail server — Formspree's API handles submission processing.
Step 1: Write the form markup
Use a standard HTML <form> with the Formspree endpoint as the action. Every field you want to receive must have a name:
<form action="https://formspree.io/f/{form_id}" method="post">
<label for="email">Your Email</label>
<input name="Email" id="email" type="email">
<button type="submit">Submit</button>
</form>
The name value becomes the field label in your submissions, so use readable names (Email, Message, Company) rather than internal codes.
Step 2: Replace {form_id} with your real ID
Swap the placeholder for the ID from your Formspree dashboard. The resulting URL looks like https://formspree.io/f/abcdwxyz. If you skip this step, submissions go nowhere.
Step 3: Submit a test entry
Open the page, fill in the form, and submit. Expected results:
- The browser posts to Formspree and you see a confirmation (or are redirected, depending on your form settings).
- The submission appears in your Formspree Inbox.
- An email notification arrives at the address tied to your account.
Formspree's own documentation states you can "create a working form in seconds" and see submissions "in under a minute," so a missing entry usually points to a markup error rather than delay.
What happens after submission
According to Formspree, the pipeline is:
| Stage | What Formspree does |
|---|---|
| Validation and spam blocking | Validates data server-side and applies machine-learning spam filtering |
| Notifications | Sends email notifications and optional auto-responses using customizable templates |
| Storage | Saves submissions to the Formspree Inbox with daily analytics; export to CSV or JSON |
| Integrations | Triggers connected services (e.g., Google Sheets, Slack, Airtable, Mailchimp, webhooks) without Zapier |
You can also add reCAPTCHA with one click or define custom spam rules if the default filter isn't enough.
Common snags and how to check them
- Nothing arrives in the inbox. Confirm the
actionURL contains your actual form ID and thatmethod="post"is present. - Fields are missing from submissions. Any input without a
nameattribute is not sent. Add names to every field, including textareas and selects. - Spam getting through. Enable reCAPTCHA or add custom rules in the form settings; Formspree's default filter is machine-learning based but tunable.
- Wrong destination email. Notifications go to the address configured for that form, so check the form's settings rather than the page markup.
When this approach fits — and when it doesn't
The plain-HTML method is the right choice when you have a static site and want submissions handled without writing or hosting server code. If you need dynamic behavior — conditional fields, multi-step forms, or programmatic submission — Formspree also offers a JavaScript library and CLI with a React library and CI/CD deployment for production forms. For a simple contact or signup form, the HTML-only route is the shortest path.
Pricing tiers and account limits are listed on Formspree's Plans page; check that page for current terms before relying on a specific submission volume.