All guides

Nuxt

Add a file-based contact route to a Nuxt site in SSR or static mode.

Copy your endpoint

Open your form in Wiztrom and copy its endpoint from Setup. Replace the example URL with that address. If you created your form from a template, use the field names and required fields from its Setup HTML.

Create the contact page

For Nuxt 4, save this as app/pages/contact.vue. In a Nuxt 3 project using the classic layout, use pages/contact.vue. The template has one root element.

Vue
<template>
  <form action="https://forms.wiztrom.com/f/YOUR_FORM_ID" method="post">
    <label>Name <input name="name" required /></label>
    <label>Email <input name="email" type="email" required /></label>
    <label>Message <textarea name="message" required></textarea></label>
    <button type="submit">Send message</button>
  </form>
</template>

Open the page outlet

The application layout must render <NuxtPage /> when you use a custom app.vue. Visit /contact in the dev server, then run your usual Nuxt build or generate command and open the published route.

Find the test in your inbox

On the published page, leave a required field empty and try Send. Fill it in, enter a distinctive test message and submit once. Open the form’s Wiztrom inbox and match the submitted values. If you enabled a notification, open delivery history and check its result.

References