Plain HTML
A classic form with no JavaScript. The browser posts it.
- Copy the HTML.
- Translate the labels.
- Optionally add a hidden _redirect field with your thank-you URL.
- The botcheck honeypot must stay empty.
Watch: your form live in two minutes
Create a form, paste the snippet into your page, and see the first submission arrive.
HTML
<form action="https://formgong.com/submit" method="POST"> <input type="hidden" name="access_key" value="fk_your_access_key"> <input type="hidden" name="_lang" value="en"> <label>Name <input type="text" name="name" autocomplete="name" placeholder="Your name" required></label> <label>Email <input type="email" name="email" autocomplete="email" placeholder="you@example.com" required></label> <label>Message <textarea name="message" placeholder="How can we help?" required></textarea></label> <div aria-hidden="true" style="position:absolute;inset-inline-start:0;top:0;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)"> <label>Leave this field empty<input type="text" name="botcheck" tabindex="-1" autocomplete="off"></label> </div> <button type="submit">Send</button> </form>
File uploads up to 100 MB
Turn on File uploads in the form's settings, verify your email, and add your site's Cloudflare Turnstile keys under Protection. Then add files.js to the page: each PDF, JPEG or PNG can be up to 100 MB, on every plan, Free included.
<form action="https://formgong.com/submit" method="POST" enctype="multipart/form-data"> <input type="hidden" name="access_key" value="fk_your_access_key"> <input name="email" type="email" required> <input type="file" name="attachment" multiple accept=".pdf,.jpg,.jpeg,.png"> <div class="cf-turnstile" data-sitekey="YOUR_TURNSTILE_SITE_KEY"></div> <button>Send</button> </form> <script src="https://challenges.cloudflare.com/turnstile/v0/api.js" async defer></script> <script src="https://formgong.com/files.js" defer></script>
- When the visitor presses Send, files.js uploads the files in 10 MB parts, waits for the antivirus check, and then sends the form. The visitor sees the progress under the form.
- Up to 3 files per submission. Account storage: 1 GiB on Free, 10 GiB on Pro.
- Without files.js the form still works, as a plain multipart post: 5 MB per file and 10 MB for all files together.
- If your own script sends the form with
fetch(new FormData(form)), keep it: files.js runs first and your handler then sends the form with an_fg_uploadfield in place of the big files. - Files are stored privately in the EU. Only you can download them after signing in, or through signed webhook links if you turn those on.
Need the fields written for you? The AI form generator turns a short description into HTML, Tailwind, Bootstrap 5, React or Vue. Preset pages: Tailwind, Bootstrap 5, booking, order, registration, contact and plain HTML, or set each field yourself in the HTML form builder. Ready designs: contact form examples and HTML contact form code. Copy the code, then paste your access key.
Moving a form from Web3Forms, Formspree or FormSubmit
Most forms move in about two minutes. Change the form's action to the Formgong /submit URL and put your Formgong key in a hidden access_key field. Formgong reads the hidden fields these services use, so you can leave them in place.
subject,from_nameandreplyto(Web3Forms) work. A field namedsubjectbecomes the email subject when the dashboard has none, and it stays in the submission._subject,_replyto,_redirect,redirectand_next(FormSubmit) work. A redirect sent by the page must stay on your own site or on an allowed domain. To send visitors to another site, set the redirect in the dashboard.- The honeypots
botcheck(Web3Forms),_gotcha(Formspree) and_honey(FormSubmit) work. _cc,_bcc,ccemail,_webhook,_autoresponse,_templateand_captchaare ignored on purpose. Anyone can read a page's HTML, so these fields would let strangers choose where your mail goes. Add extra recipients, webhooks and the autoreply in the dashboard instead.
Send one test submission and open it in the Formgong inbox before you remove the old service.
Ready starter on GitHub: github.com/formgong/html-starter. MIT license: click “Use this template” or copy the files.
New project in one command: npm create formgong@latest -- --template html (npm: create-formgong)
Add to an existing project: npx formgong init (npm: formgong)
Articles on this topic
- Form without a backend: 7 ways that work
- HTML contact form without a backend: a working example
- Thank-you page after form submission (HTML)
- HTML form action attribute explained
- Web3Forms alternatives compared