PortForm
All templates

Contact form popup

A dialog that opens over the page instead of taking you to a contact page. It uses the native <dialog> element, so Escape closes it and focus is trapped without a line of code from you; Alpine only carries the sending state. Tailwind and Alpine both come from a CDN so the file runs as-is. If your site already builds Tailwind, drop the CDN script and keep the markup.

TailwindCSS · Alpine.js · HTML

Replace YOUR_ACCESS_KEY with the access key from your dashboard. Create one free. The endpoint and the honeypot are already in place.

Useful for

The part behind every one of these is a form backend. This template posts to a PortForm form endpoint; the docs cover the fields and responses.

Your form works in about a minute.

We use optional analytics cookies to understand how the site is used. Necessary cookies for signing in and checkout always load. See our privacy policy.