Forms on AI-built websites

AI website builders and coding assistants write good forms, but usually nothing that receives them, so the form does nothing when someone presses Send. FormDoc is the missing part. You keep the form the AI made and change where it sends.

What to change

  1. Get an access key at app.formdoc.dev/new.
  2. Set the form’s action to https://api.formdoc.dev/v1/submit and its method to POST.
  3. Add a hidden field: <input type="hidden" name="access_key" value="YOUR_ACCESS_KEY">.
  4. Make sure every input has a name attribute, such as name, email and message.
  5. Add the hidden spam trap: <input type="checkbox" name="botcheck" style="display:none" tabindex="-1" autocomplete="off">.

A prompt for your AI assistant

Paste this into your builder or coding assistant, with your key filled in:

Make the contact form send its submissions to FormDoc:
- Set the form's action to https://api.formdoc.dev/v1/submit and method to POST.
- Add a hidden input named access_key with the value YOUR_ACCESS_KEY.
- Give every input a name attribute (name, email, message).
- Add a hidden checkbox named botcheck (display:none, tabindex -1, autocomplete off) as a spam trap.
- Remove any API route, server action or email code that was meant to send this form.

If the site uses its own JavaScript to submit

Some generated forms send with JavaScript instead of a normal post. In that case ask for a fetch call that posts the form’s data to https://api.formdoc.dev/v1/submit with the header Accept: application/json, and shows the message from the JSON response. The Next.js guide has a complete example.

Test it

Publish the site, send yourself a message and check your inbox. If nothing arrives, confirm your email address first; the FAQ covers the other common causes.