Quick Start
Install
Section titled “Install”For Webflow’s native success and error states, add this script before </body> in your project:
<script src="https://cdn.jsdelivr.net/npm/formtress-js@0.2.1/dist/js/webflow.js"></script>Connect your form
Section titled “Connect your form”-
Create a form in the dashboard
Log in to your Formtress dashboard, create a workspace (or use your default one), and add a new form. You’ll see a Form ID at the top of the form page — click it to copy.
-
Set your form’s action
Set the
actionattribute to your Formtress submit URL andmethodtopost:<form action="https://app.formtress.com/api/f/your-form-id-here" method="post"><input type="text" name="name" placeholder="Name" required /><input type="email" name="email" placeholder="Email" required /><textarea name="message" placeholder="Message"></textarea><button type="submit"><span data-ft-loading-text="Sending...">Send</span></button></form>Replace
your-form-id-herewith your actual Form ID. -
Submit a test
Open your page, fill in the form, and hit submit. You should see the submission appear in your dashboard immediately.
Install the Formtress package:
npm install formtress-jspnpm add formtress-jsyarn add formtress-jsbun add formtress-jsConnect your form
Section titled “Connect your form”-
Create a form in the dashboard
Log in to your Formtress dashboard, create a workspace (or use your default one), and add a new form. You’ll see a Form ID at the top of the form page — click it to copy.
-
Set the form action and enhance with JavaScript
Set the
actionon your form, then intercept it withsubmitForm:<form id="my-form" action="https://app.formtress.com/api/f/your-form-id-here" method="POST"><!-- your fields --><button type="submit">Send</button></form>import { submitForm } from 'formtress-js'const form = document.querySelector('#my-form')form.addEventListener('submit', async (e) => {e.preventDefault()const result = await submitForm({url: form.action,data: new FormData(form),})if (result.ok) {// Show your own success UI} else {// Show error state: result.message, result.status}}) -
Submit a test
Open your page, fill in the form, and hit submit. You should see the submission appear in your dashboard immediately.
What happens next?
Section titled “What happens next?”- Webflow users — the script automatically uses Webflow’s native success/error states. See the full Webflow Guide.
- Vanilla JS users — handle success/error in code. See the Vanilla JS Guide.
- Set up integrations — forward submissions to email or webhooks. See Integrations.