Plain HTML
A <form action> and a _redirect. The post gets a 303 back to your thank-you page. No JavaScript, no build step.
fetch, React, Astro, Next.js
GET /v1/forms/{id}/embed returns snippets for each, rendered for your form's fields. Next.js server actions keep the submit URL off the client if you prefer; Astro and React post from the browser with an origin allowlist and CORS handled for you.
"use server"
export async function submitForm(formData: FormData) {
await fetch("https://postbag.dev/s/fm_8f3kq2", { method: "POST", body: formData })
} "use server"
export async function submitForm(formData: FormData) {
await fetch("https://postbag.dev/s/fm_8f3kq2", { method: "POST", body: formData })
} Host-independent
Netlify Forms only works on Netlify. Postbag works on Cloudflare Pages, Vercel, GitHub Pages, S3, a VPS, or all of them at once, and survives a migration because the form posts to Postbag, not to the host.