Free tool

AI form generator

Formgong team ·

Type what the form should ask, or start from one of eight common forms. You get HTML, Tailwind, Bootstrap 5, React, Vue and a prompt for AI site builders, all from the same fields.

Short answer: An AI form generator turns a plain description into form code you can paste into a page. This one fills in editable fields, shows a live preview, and returns HTML, Tailwind, Bootstrap 5, React, Vue and an AI builder prompt. The form posts to Formgong once you paste your free access key. Until then, nothing is sent.

Build your form

Pick a starting form or describe yours, then edit the fields. The preview and the code change as you type. The AI answer is checked against a fixed list of field types, and your description is never printed as HTML.

New: open this form in the form builder to give it your site's colours and font and get the code for WordPress, Shopify, Wix or Webflow.

1. Start from a form

Or describe the form and let AI fill in the fields

Only your description goes to the AI model. The answer replaces the fields above it, and you can edit them like any other.

2. Edit the fields

3. Check the live preview

This is the HTML tab, rendered. Paste your access key in step 4 and the button sends a real test submission.

Contact us

Form by Formgong

4. Add your access key

Every copy below uses it as you type. Until then the code has fk_your_access_key, which Formgong refuses.

We email you a sign-in code. Your first form and its key are ready once you enter it. Enter the code in this tab and the form's Connect page starts with these fields.

5. Copy the code

Plain HTML with a short style block. The script at the end is optional: it keeps visitors on the page and says sent only when Formgong answers success: true. Delete it and the browser posts the form on its own.

HTML
<style>
#fg-form{position:relative;box-sizing:border-box;display:grid;gap:16px;width:100%;max-width:520px;padding:28px;border:1px solid #dbe2ea;border-radius:8px;background:#fff;color:#0f172a;font:16px/1.5 system-ui,sans-serif}
#fg-form *{box-sizing:border-box}
#fg-form h2{margin:0;font-size:24px;line-height:1.3}
#fg-form .fg-field{display:grid;gap:6px;min-width:0;margin:0;padding:0;border:0}
#fg-form label,#fg-form legend{font-weight:500}
#fg-form legend{padding:0;margin-bottom:2px}
#fg-form input,#fg-form select,#fg-form textarea{width:100%;min-height:44px;padding:10px 12px;border:1px solid #64748b;border-radius:8px;background:#fff;color:inherit;font:inherit}
#fg-form textarea{min-height:120px;resize:vertical}
#fg-form .fg-choice{display:flex;align-items:center;gap:10px;font-weight:400}
#fg-form .fg-choice input{width:20px;min-height:20px;margin:0;flex-shrink:0}
#fg-form [aria-invalid=true]{border-color:#b91c1c}
#fg-form .fg-error{margin:0;color:#b91c1c;font-size:14px}
#fg-form .fg-status{margin:0}
#fg-form .fg-credit{margin:0;font-size:13px;text-align:center}
#fg-form .fg-credit a{color:#64748b}
#fg-form .fg-error:empty{display:none}
#fg-form button{min-height:48px;padding:12px 20px;border:0;border-radius:8px;background:#4338ca;color:#fff;font:inherit;font-weight:600;cursor:pointer}
#fg-form button:disabled{opacity:.7;cursor:wait}
#fg-form :focus-visible{outline:3px solid #4338ca;outline-offset:3px}
#fg-form .fg-trap{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}
#fg-form select{appearance:none;-webkit-appearance:none;padding-inline-end:40px;background-image:linear-gradient(45deg,transparent 50%,currentColor 50%),linear-gradient(135deg,currentColor 50%,transparent 50%);background-position:calc(100% - 20px) 50%,calc(100% - 15px) 50%;background-size:5px 5px,5px 5px;background-repeat:no-repeat}#fg-form select:dir(rtl){background-position:15px 50%,20px 50%}@media (forced-colors:active){#fg-form select{appearance:auto;-webkit-appearance:auto;background-image:none}}
</style>
<form id="fg-form" action="https://formgong.com/submit" method="POST">
  <h2>Contact us</h2>
  <input type="hidden" name="access_key" value="fk_your_access_key">
  <input type="hidden" name="_lang" value="en">
  <div class="fg-field">
    <label for="fg-name">Name <span aria-hidden="true">*</span></label>
    <input type="text" id="fg-name" name="name" autocomplete="name" required aria-describedby="fg-name-error" placeholder="Jane Smith">
    <p class="fg-error" id="fg-name-error"></p>
  </div>
  <div class="fg-field">
    <label for="fg-email">Email <span aria-hidden="true">*</span></label>
    <input type="email" id="fg-email" name="email" autocomplete="email" required aria-describedby="fg-email-error" placeholder="jane@example.com">
    <p class="fg-error" id="fg-email-error"></p>
  </div>
  <div class="fg-field">
    <label for="fg-message">Message <span aria-hidden="true">*</span></label>
    <textarea id="fg-message" name="message" required aria-describedby="fg-message-error" placeholder="How can we help?" rows="4"></textarea>
    <p class="fg-error" id="fg-message-error"></p>
  </div>
  <div class="fg-trap" aria-hidden="true"><label>Leave this empty <input type="text" name="botcheck" tabindex="-1" autocomplete="off"></label></div>
  <button type="submit">Send message</button>
  <p class="fg-status" data-fg-status role="status"></p>
  <p class="fg-credit"><a href="https://formgong.com/en/?ref=badge&amp;utm_source=badge&amp;utm_medium=form&amp;utm_campaign=generator" target="_blank" rel="noopener">Form by Formgong</a></p>
</form>
<script>
// Optional. Without it the browser posts the form and Formgong shows its own thank-you or error page.
(function () {
  var form = document.getElementById("fg-form");
  var status = form.querySelector("[data-fg-status]");
  form.noValidate = true;
  form.addEventListener("submit", function (event) {
    event.preventDefault();
    var first = null, seen = {};
    Array.prototype.forEach.call(form.elements, function (field) {
      var id = field.getAttribute("aria-describedby");
      if (!id || seen[id]) return;
      seen[id] = true;
      var ok = field.checkValidity();
      field.setAttribute("aria-invalid", ok ? "false" : "true");
      document.getElementById(id).textContent = ok ? "" : field.validationMessage;
      if (!ok && !first) first = field;
    });
    if (first) { first.focus(); return; }
    var button = form.querySelector("[type=submit]");
    button.disabled = true;
    status.textContent = "Sending…";
    fetch(form.action, { method: "POST", headers: { Accept: "application/json" }, body: new FormData(form) })
      .then(function (response) { return response.json().catch(function () { return {}; }); })
      .then(function (data) {
        if (data.success === true) { form.reset(); status.textContent = "Thank you. Your message was sent."; }
        else status.textContent = data.message || "Could not send. Please try again.";
      })
      .catch(function () { status.textContent = "Could not reach the server. Check your connection and try again."; })
      .then(function () { button.disabled = false; });
  });
})();
</script>
<!-- Optional: fg.js counts views, starts and the field people stop at for your Formgong Analytics page. No cookies. Delete this line to turn it off. -->
<script src="https://formgong.com/fg.js" defer></script>

How to use the form generator

  1. Start from a form: contact, quote request, booking, job application, feedback, newsletter, event registration or support request. Or describe yours in a sentence and let AI fill in the fields.
  2. Edit the fields. Each row has a label, a type, a placeholder, a Required box and, for lists, the options. The arrows move a row; Remove deletes it.
  3. Watch the preview. It is the HTML tab, rendered, and it changes as you type.
  4. Paste your access key. Every copy picks it up, and the preview's button then sends a real test submission.
  5. Copy one of six versions: HTML, HTML with Tailwind, Bootstrap 5, React, Vue, or a prompt for an AI site builder.

Editing the fields runs in your browser. Only the AI description is sent anywhere, so the limits below apply to that box and nothing else.

A few searches want one form already filled in. Open the Tailwind form generator, the Bootstrap form generator, the booking form generator, the order form generator, the registration form generator, the contact form generator or the HTML form generator. To set every field yourself, one row at a time, use the HTML form builder.

Presets by form type: survey, feedback, newsletter signup, RSVP and job application.

What makes a generated form actually send

On 2 November 2026, 0 of the 16 generators on Google's first page for “html form generator” gave us a form that sends as copied, and 0 of the 7 that show code added spam protection. Every copy here has a real target, your key, field names, an honest success message and a honeypot. The HTML form generator page shows what we tested and what is in the code.

HTML form code, contact forms and the other copies

The HTML tab is a classic form with a short style block. The browser posts it to /submit, so it works with no JavaScript. The script at the end is optional: it keeps the visitor on the page and fills each field's error line. The Tailwind tab is the same form with utility classes, for a site that already loads Tailwind. The Bootstrap 5 tab uses form-control, form-select and btn, for a site that already loads Bootstrap 5.

The React and Vue tabs are components. They check each field, send FormData, read the JSON answer, and write success or failure into a status line. They do not invent a backend. The AI builder prompt describes the same form in words for Lovable, Bolt, v0, Claude or Cursor, and tells the builder not to make a server of its own.

Every field has a label tied to it with for and id. Radio buttons and checkbox groups sit in a fieldset with a legend. Each field points at its own error line with aria-describedby, so a screen reader reads the problem with the field. A file field adds enctype="multipart/form-data"; files need Uploads turned on for your form.

Free limits, email and where data is stored

Copying code needs no account. AI generations are limited to 5 an hour and 10 a day for each network, plus 100 a day for the whole site. When a limit is hit, the page says so; starting from a form and editing the fields still works.

On the free plan, Telegram alerts are instant and email is sent for every submission. The free plan allows 250 submissions a month. Auto-reply is not on the free plan. Submission data is stored in the EU.

Your description is sent to the AI model so it can choose fields. It is not stored as a submission. Do not paste passwords, card numbers or other secrets. The form checker can read the published page later and list problems such as a missing action or the placeholder key still in place.

What this generator does not do

This page does not host the form, take payments, or branch questions. A hosted form builder is a better fit for that. It also does not save your work: reload the page and the editor starts over, so copy the code when you are done.

The code will not deliver mail until the placeholder key is a real Formgong key. Support is Formgong at support@formgong.com.

Tell us what is missing

Built a form here that did not do what you needed? Write to support@formgong.com with the form you were trying to make: a field type we lack, a framework tab you want, or a place the code broke. We read every message and answer it.

Questions

What is an AI form generator?

It builds a form from a short description. This page returns HTML, Tailwind, Bootstrap 5, React, Vue and a prompt for AI site builders. It does not keep the form on Formgong until you create a free key.

Can I get plain HTML without describing the form?

Yes. The HTML form generator page starts from a ready sample and gives plain HTML with labels, required fields and a honeypot. The HTML tab here is the same code. Copying is free and needs no account.

Why does a generated form not send anything?

Usually because its action is empty, or it points at a placeholder endpoint. A form needs a real address to post to and, for a form backend, a key. Here the action already points to Formgong; paste your key and the preview sends a real test.

How do I get contact form HTML code?

Choose Contact at the top, or describe the fields you want. Copy the HTML tab. Put your access key in step 4, or in the hidden access_key field. The HTML guide shows the same kind of form with every hidden field Formgong understands.

Can I use it with Lovable, Bolt or v0?

Yes. Copy the AI builder prompt tab and paste it into the builder. It lists the fields, names and checks, the address to post to, and tells the builder not to add a backend.

Will the form send email?

After you replace the placeholder key, yes. On the free plan, Telegram is instant and email is sent for every submission. Data is stored in the EU. The free plan is 250 submissions a month.

Can I build the form without AI?

Yes. Start from one of the eight forms, or from the sample, and edit the rows. That runs in your browser and never calls the model, so there is no limit on it.

Sources

Checked on 20.10.2026 against these public pages: MDN: <form>, Formgong HTML guide, splitforms AI form generator, Grigora AI form builder, FormSubmit form generator, gizza HTML form generator.

← Formgong