splitforms.com

Contact form · Alpine.js

Contact form for Alpine.js sites

Alpine.js's tiny footprint pairs naturally with splitforms — declare x-data for state, @submit.prevent for the handler, and POST to splitforms. No build step, no SPA framework, no server route.

  • 500 free / mo
  • 14ms latency
  • No backend code
Alpine.js contact form — copy-paste code for splitforms

No backend code

No server, API route, or SDK. Your Alpine.js form posts straight to one endpoint.

Straight to your inbox

Every submission is emailed to you and saved to a searchable dashboard — spam filtered before it reaches you.

Design without limits

It's your own Alpine.js markup and styles. Splitforms is only the backend, so nothing constrains how the form looks.

Copy-paste ready

Your Alpine.js contact form, ready to paste.

Replace YOUR_ACCESS_KEY with the key from your dashboard — that's the whole integration. No SDK to install, no build step, just the html you already write.

Generate access key
contact.html
<form
  x-data="{
    status: 'idle',
    async submit(e) {
      this.status = 'loading';
      const fd = new FormData(e.target);
      const res = await fetch('https://splitforms.com/api/submit', {
        method: 'POST', body: fd
      });
      const data = await res.json();
      this.status = data.success ? 'ok' : 'err';
      if (data.success) e.target.reset();
    }
  }"
  @submit.prevent="submit"
>
  <input type="hidden" name="access_key" value="YOUR_ACCESS_KEY" />
  <input name="name" required />
  <input name="email" type="email" required />
  <textarea name="message" required></textarea>
  <input type="checkbox" name="botcheck" style="display:none" tabindex="-1" />
  <button :disabled="status === 'loading'" type="submit">
    <span x-show="status === 'idle'">Send</span>
    <span x-show="status === 'loading'">Sending…</span>
  </button>
  <p x-show="status === 'ok'">Thanks!</p>
  <p x-show="status === 'err'">Error — try again.</p>
</form>

How to add it

How to add a contact form to a Alpine.js website.

To add a contact form to a Alpine.js website you need three things: a free splitforms access key, the html snippet above, and your key pasted into it. No backend, server, or SDK — the form posts to one URL and every submission lands in your inbox and dashboard.

Get your free splitforms access key

Sign up at splitforms.com, verify your email, and copy your access key from the dashboard. No credit card required.

Drop the Alpine.js snippet into your project

Copy the Alpine.js code example into your project and replace YOUR_ACCESS_KEY with the key from step 1.

Receive submissions in your dashboard

Submissions arrive in the splitforms dashboard within seconds. Free includes inbox delivery; Pro adds Slack, Discord, Sheets, or any signed webhook URL.

Where submissions go

Where do your Alpine.js form submissions go?

Every submission is emailed to you and saved to a searchable dashboard — spam filtered before it ever reaches you. Search, export to CSV, or forward it to a webhook or Slack on Pro.

  • 500 submissions per month, free forever
  • Honeypot + AI spam classifier on every plan
  • Signed webhooks to Slack, Discord, your server
Alpine.js contact form submissions in the splitforms dashboard

No backend needed

Do you need a backend for a Alpine.js form? No.

Your Alpine.js form posts standard FormData to one URL. Splitforms validates the access key, runs the spam classifier, and forwards it to your email — so there's no server, API route, or database for you to build or maintain.

  • Drop into any HTML page — no build step, no bundler
  • State machine declared inline via x-data — no separate JS file
  • Works with every Alpine.js plugin (Persist, Focus, Morph, Mask)
How splitforms processes a Alpine.js form submission

Best practices

What a production-ready Alpine.js form needs.

The difference between a form that works in the demo and one that survives launch traffic — the production-tested defaults, in priority order.

  • Lock the access key to your domains. The dashboard accepts a list — anyone copying the key from your bundle can't replay it from another origin.
  • Add the hidden honeypot input. Bots fill every field; humans don't see it. Splitforms rejects any submission that has it set.
  • Show submit state visually. Disable the button and label it 'Sending…' while the request is in flight — users hammer submit on slow networks otherwise.
Production-ready Alpine.js contact form best practices

How SplitForms works

From form to workflow in 3 simple steps.

Connect your form, collect every submission, and send data where it needs to go — without building backend infrastructure.

A SplitForms contact form submission launching straight to your inbox

Add your endpoint

Point your form to your unique SplitForms endpoint. That's it.

HTML form pointing at a SplitForms submit endpoint

Receive submissions

We instantly capture and organize every submission in your inbox.

Submissions inbox with searchable leads and status pills

Route anywhere

Send data to email, spreadsheets, CRMs, webhooks, and 7,000+ apps.

Generic integration tiles for email, sheets, chat, CRM, automate, and webhook

No credit card required. Set up in under 60 seconds.

Connect & automate

Connect your favorite tools and automate everything

SplitForms works with the destinations you route to and the platforms you build on — from Slack and Sheets to WordPress, Shopify, and Next.js.

Connect your SplitForms form to Slack, Google Sheets, Mailchimp, Zapier and more

Trusted by indie teams and agencies shipping forms worldwide

PETAL/COKRAFT.DELINEAR-XBUILD.DEVSTUDIO 71MERIDIANFRAME&CO

Testimonials

Loved by developers shipping at every scale.

40 quotes on record — from indie hacks to agency migrations.

Questions

Alpine.js contact form questions.

View all FAQs
Is splitforms really free?

Yes — 500 dashboard submissions per month forever, no credit card. Pro is $5/mo for delivery features and retained uploads when Storage is connected; Pro is $5/mo for 5,000 submissions.

Do I need to install anything?

No. Splitforms is API-only. There's no SDK, no plugin, no PHP. Your form posts standard FormData to one URL.

How do you handle spam?

A hidden honeypot field catches the obvious bots. A tuned classifier scores everything else and quarantines the noise. You see clean submissions only.

Can I keep my access key out of the bundle?

Yes — use a server-side environment variable and post from a server route or server action. Or expose it client-side and rely on per-domain locking. Either path is supported.

Simple pricing

Start free. Scale when you need more.

Choose a plan that fits your workflow — from a free form endpoint to full automations, exports, and higher submission limits.

Free

$0

Free forever

 
Best for testing

For side projects and indie devs.

  • 500 submissions / mo
  • Unlimited forms
  • Email notifications included
  • Honeypot spam filtering
  • Submissions dashboard
  • MCP setup stays free
  • No credit card required

3-Year

$59/ 36 months
was $99 · save 40% · new-user price

Pay $59. 3 years sorted.

  • 15,000 submissions / mo
  • Unlimited forms
  • Everything in Pro
  • Renews every 3 years
  • Long-term discount
  • Priority support included
  • Vote on the roadmap

No credit card required on Free • Cancel anytime