# Quick start

> Add a working form to any website in five minutes. No backend, no JavaScript required.

Last updated 2026-11-19. Web version: https://wrenform.com/docs

```html
<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>
```

**Fastest path:** tell your AI tool "add a contact form with Wrenform" (see [AI tools](/docs/ai)). Or create a form in the dashboard, copy its action URL, and paste it into `<form action="…" method="POST">`.

Replace `YOUR_FORM_ID` with your form's ID. That's the whole integration.

## 1. Create a form

[Sign in](/sign-in) with your email or Google (it's free) and create a form. Copy its endpoint from the form's **Setup** page. It looks like `https://wrenform.com/f/YOUR_FORM_ID`. The form ID isn't a secret: it's meant to sit in your HTML.

Using a coding agent? It can't create the form for you. Create it yourself, then give the agent the form ID.

## 2. Paste the HTML

Set your form's `action` to the endpoint and its `method` to `POST`.

- Give every input a `name`. Fields without one aren't sent.
- Keep the hidden `_honey` field. Bots fill it in; people don't.
- Name the address field `email`. It becomes the reply-to of the email you get.

## 3. Test it

Open your page, fill in the form and send it. You land on a thank-you page, the submission appears in your dashboard, and an email arrives at your sign-in address. You can also press **Send test submission** on the form's Setup page.

**Send test submission** checks that email arrives. It doesn't prove your live page works: deploy, then submit once from the real page. It should show up in your dashboard Inbox.

## 4. Lock it to your site

In the form's settings, add your site to **Allowed origins**, for example `https://example.com`, or `https://*.example.com` for its subdomains. Other sites then can't post to your form. While the list is empty, any site can.

## Redirect or JSON

The endpoint answers in one of two modes, chosen per request:

- **Browser mode** (a normal form post): on success, a `303` redirect to your thank-you page or ours. On error, a hosted error page with the same HTTP status. See [redirects](/docs/redirects).
- **JSON mode**: when the body is `application/json`, or the `Accept` header lists `application/json` before `text/html`. You get `200` with `{ "ok": true, "id": "…" }`, or an error object with a stable `code`.

```json
{ "ok": true, "id": "01JD3K2M9X7Q8R4T5V6W7Y8Z9A" }
```

```json
{
  "ok": false,
  "error": {
    "code": "origin_not_allowed",
    "message": "This form doesn't accept messages from this website.",
    "docs": "https://wrenform.com/docs/errors#origin_not_allowed"
  }
}
```

```text
HTTP/1.1 303 See Other
Location: https://example.com/thanks
```

Spam is answered exactly like success, so bots learn nothing. Accepted content types: `application/x-www-form-urlencoded`, `multipart/form-data` (text fields only; files are dropped) and `application/json` (a flat object).

Sending from JavaScript instead:

```js
const res = await fetch("https://wrenform.com/f/YOUR_FORM_ID", {
  method: "POST",
  headers: { "Content-Type": "application/json", Accept: "application/json" },
  body: JSON.stringify({ name: "Ada", email: "ada@example.com", message: "Hello" }),
});
const result = await res.json();
// Success: { ok: true, id: "..." }
// Error:   { ok: false, error: { code, message, docs } }
if (!result.ok) console.error(result.error.code, result.error.message);
```

## Limits

- Request body: 64 KB. Up to 100 fields; names up to 100 characters; values up to 10,000 characters.
- Rate limits: 10 a minute and 50 an hour per visitor and form; 60 a minute per form.
- Monthly submissions: 250 on the free plan; see [pricing](/pricing). Past your quota, submissions are stored but not emailed.

More in [fields and limits](/docs/fields).

## Error codes

| Code | HTTP | Message |
|---|---|---|
| [`form_not_found`](/docs/errors#form_not_found) | 404 | This form doesn't exist or has been deleted. |
| [`form_paused`](/docs/errors#form_paused) | 403 | This form isn't accepting messages right now. |
| [`form_suspended`](/docs/errors#form_suspended) | 410 | This form has been suspended. |
| [`origin_not_allowed`](/docs/errors#origin_not_allowed) | 403 | This form doesn't accept messages from this website. |
| [`payload_too_large`](/docs/errors#payload_too_large) | 413 | The message is too large. |
| [`too_many_fields`](/docs/errors#too_many_fields) | 422 | The form has too many fields. |
| [`field_too_long`](/docs/errors#field_too_long) | 422 | One of the fields is too long. |
| [`unsupported_media_type`](/docs/errors#unsupported_media_type) | 415 | The form was sent in a format we can't read. |
| [`invalid_json`](/docs/errors#invalid_json) | 422 | The JSON body is invalid or nested. |
| [`empty_submission`](/docs/errors#empty_submission) | 422 | The form was empty. |
| [`rate_limited`](/docs/errors#rate_limited) | 429 | Too many messages. Please wait a minute and try again. |
| [`quota_exceeded`](/docs/errors#quota_exceeded) | 429 | This form can't accept more messages this month. |
| [`form_pending_confirmation`](/docs/errors#form_pending_confirmation) | 429 | This form is waiting for its owner to confirm it, and can't take more messages until then. |
| [`internal_error`](/docs/errors#internal_error) | 500 | Something went wrong on our side. |

## Common problems

- **Nothing arrives.** Check that every input has a `name`, and that the form's `method` is `POST`.
- **`origin_not_allowed`.** Your page's origin isn't in the allowed list, or you opened the HTML as a local file. Test from a web server.
- **The email went to spam.** See [notifications](/docs/notifications) to allow-list our sender.
- **Something else.** See [my form isn't working](/docs/troubleshooting): each symptom with its cause and fix.

## Next steps

- Pick your stack: [HTML](/docs/frameworks/html), [Astro](/docs/frameworks/astro), [Next.js](/docs/frameworks/nextjs), [Hugo](/docs/frameworks/hugo), [Framer](/docs/frameworks/framer), [Webflow](/docs/frameworks/webflow).
- Site with a strict Content-Security-Policy? Use the [no-JavaScript form](/docs/frameworks/html#strict-content-security-policy-sites).
- Tune [spam filtering](/docs/spam), send to your own [thank-you page](/docs/redirects), or add [webhooks](/docs/webhooks) (Pro and Agency).
- Forwarding this to a client? Send them [where the data lives](/docs/privacy).
- New to forms on a static site? Read [contact forms for static websites](/contact-form/static-site). Coming from another service? Compare [Formspree](/alternatives/formspree), [Web3Forms](/alternatives/web3forms), [Getform](/alternatives/getform) and [others](/alternatives/basin).
