Skip to Content
FeaturesCustom Redirects

Custom Redirects

Available on all plans. See pricing.

By default, Formtorch shows its own success page after a form is submitted. You can override this and redirect users to any URL you choose — your own thank-you page, a pricing page, a calendar link, or anywhere else.

Setting a redirect URL

Add a hidden _redirect field to your form with the destination URL:

<form action="https://formtorch.com/f/YOUR_FORM_ID" method="POST"> <input type="hidden" name="_redirect" value="https://yoursite.com/thank-you" /> <input type="text" name="name" placeholder="Your name" /> <input type="email" name="email" placeholder="Your email" /> <button type="submit">Submit</button> </form>

After a successful submission, Formtorch redirects the browser to https://yoursite.com/thank-you.

AJAX and fetch submissions

If you’re submitting the form via JavaScript (fetch or XMLHttpRequest), the redirect field is ignored. Instead:

  • Include X-Requested-With: XMLHttpRequest in your headers
  • Formtorch returns a JSON response instead of redirecting
  • Handle the success state yourself in your JavaScript
const res = await fetch("https://formtorch.com/f/YOUR_FORM_ID", { method: "POST", headers: { "X-Requested-With": "XMLHttpRequest" }, body: new FormData(formEl), }); if (res.ok) { // Show your own success message }

Reserved fields

Fields prefixed with _ are control fields and are not stored as submission data:

FieldPurpose
_redirectURL to redirect to after submission
_formNameOverride the form name shown in notification emails
_testMark submission as a test (set to true)
_honeypotHidden honeypot field (leave empty)
_honeypotFieldCustom honeypot field name

The _redirect URL must be an absolute URL (starting with https://). Relative URLs are not supported.

Last updated on