All guides

Contact form for WordPress (static export)

Static-export plugins (such as Simply Static or WP2Static) turn WordPress into plain HTML for cheap, fast hosting. Form plugins like Contact Form 7 or WPForms post back to WordPress (PHP), which no longer exists on the static copy, so they stop working. A Pasteform form is plain HTML and survives the export.

Get my free form link Replace YOUR_FORM_ID below with your form ID, or copy the snippets from your dashboard where it's already filled in.

Step by step

  1. Create a form in Pasteform and copy the HTML snippet.
  2. In the WordPress editor, add a Custom HTML block on your contact page and paste the snippet. Remove the old form plugin's block or shortcode.
  3. Run your static export and deploy it.
  4. Add the static site's domain to Allowed domains (and the WordPress admin domain if you also want previews to work).

Custom HTML block

<form action="https://forms.prizenlabs.com/f/YOUR_FORM_ID" method="POST">
  <label>Name <input type="text" name="name" required></label>
  <label>Email <input type="email" name="email" required></label>
  <label>Message <textarea name="message" required></textarea></label>
  <input type="text" name="_gotcha" style="display:none" tabindex="-1" autocomplete="off">
  <button type="submit">Send</button>
</form>

Allowed domains

Add the domain of the static site (and the WP admin domain for previews).

Common pitfalls

What you get

Make your WordPress (static export) form send

Free form link in about 2 minutes. No credit card.

Get my free form link

Guides for other platforms

Lovable · Bolt · v0 · Framer · Webflow · Astro · Next.js · Hugo · Jekyll · GitHub Pages · Netlify · Vercel · Carrd · plain HTML