ChatGPT / Claude contact form

Formgong team ·

Paste this into ChatGPT / Claude. Posts go to Formgong. No database and no Resend.

250 free submissions a month

How forms work in ChatGPT / Claude

ChatGPT and Claude write the page, but they do not host it and they do not run a backend. Without exact instructions they tend to invent an endpoint, copy syntax from other form services, or leave a form that goes nowhere.

Give the model the Formgong prompt below and the form will post to https://formgong.com/submit with the right fields. Then host the file anywhere that serves static pages, such as GitHub Pages, Netlify or Cloudflare Pages.

Set it up in ChatGPT / Claude

  1. Create a form in Formgong and copy the access key.
  2. Paste the prompt below into ChatGPT or Claude together with your page, or ask for a new page. You can also give the model https://formgong.com/llms.txt as a reference.
  3. Download the result. A plain HTML form works without JavaScript; the visitor sees Formgong's thank-you page, or your own page if you set _redirect.
  4. Upload the files to your host and send a test from the live page, not from the chat preview.

Step-by-step guide in the docs

ChatGPT / Claude
When you build this website, include a working contact form as a plain HTML <form> in the same file, so it works on any static host without JavaScript. Submissions go to Formgong, a hosted form backend.

Formgong spec (follow exactly):
- Plain HTML: <form action="https://formgong.com/submit" method="POST">. With JavaScript, POST the same fields to https://formgong.com/submit using fetch.
- Hidden field access_key with value fk_your_access_key. The key is public and belongs in frontend code. Do not move it to a server or a secret.
- Hidden field _lang with the page language code, e.g. "en" (on multilingual sites use document.documentElement.lang). Formgong uses it for error messages, the thank-you page, and the autoreply.
- Fields: name, email, message (required); phone is optional. Keep these field names, and use <input type="email"> for email so browsers check the address.
- Honeypot: <input type="text" name="botcheck" tabindex="-1" autocomplete="off"> inside a wrapper with aria-hidden="true", visually hidden with CSS (position:absolute;inset-inline-start:0;top:0;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)). Never fill it.
- Success, plain form POST: optionally add a hidden _redirect field with the absolute https URL of the site's thank-you page. Without it, Formgong shows its own thank-you page.
- Success, fetch: send Accept: application/json (and Content-Type: application/json for a JSON body; for FormData let the browser set it). If the response has success === true, show an inline thank-you message and reset the form; otherwise show the response's message.
- Turnstile: only if I give you a Cloudflare Turnstile site key, add <script src="https://challenges.cloudflare.com/turnstile/v0/api.js" async defer></script> and <div class="cf-turnstile" data-sitekey="SITE_KEY"></div> inside the form. Otherwise leave it out.
- Optional: add <script src="https://formgong.com/fg.js" async></script> once per page. It fills _lang from <html lang>, sets the Turnstile language, and counts form views without cookies.
- Do not create a backend, API route, server function, database table, or email-sending code (Supabase, Resend, SendGrid, nodemailer), and do not add secrets. No file uploads.

Formgong or a form the model writes?

If you already run a server with its own form handling, ask the model to use it instead.

For a static page there is no other place to send the form: Formgong receives it, filters spam and forwards it to email and Telegram.

Questions and answers

Why did the form not send from the chat preview?

Preview panes such as Claude artifacts or ChatGPT canvas run in a sandbox that may block requests to other sites. The same code works once the page is hosted.

Which hosting should I use?

Any host that serves static files: GitHub Pages, Netlify, Cloudflare Pages or your own server. Formgong does not depend on the host.

The model changed the field names. Does that matter?

Only access_key, botcheck and the fields starting with an underscore have fixed names. Your own fields can have any name; they show up as written.

Start free