Prosphere

NotesGuides

Contact Form Without a Backend: Four Ways and What Each Costs

A static site can show a contact form but not process it. Four ways to get submissions to your email, from mailto to a hosted form service, compared.

In this post

A static site is a set of files that the server sends as they are. When a visitor submits a contact form on such a site, no code on the site runs to receive the message, so the form has to send its data to something else. This post explains what the browser does on submit, then compares four ways to get submissions to your email, by what you have to run and maintain for each.

Why a static site cannot process a form

A page made only of HTML and CSS has no code running on the server when someone presses a button. The page can show the fields and the button, and the browser can collect what the visitor typed. Something else has to receive the result and decide what happens to it: store it, check it, or pass it on to an inbox.

That receiving end is the target of the form. The page itself does not do it, and no part of a static site does it by default. Once you see that, the four options below are easier to compare, because each one is just a different answer to the question "who receives this?"

What a browser does when a form is submitted

The form element carries the details. Its action attribute sets the URL that processes the submission. Its method attribute sets how the data travels. The value get is the default and appends the data to the action URL after a ?. The value post sends the data in the body of the request. The browser collects the form's named controls and sends them to that action.

So every option below comes down to two things: which URL is the action, and what code runs behind that URL. The rest is detail about who writes that code and who keeps it running.

A mailto: link is not a form submission. The mailto scheme identifies a mailbox, and it can carry a subject and a body. Clicking the link asks the visitor's mail client to create a message to that address with those fields filled in. The RFC is explicit that the user remains in control of the result: the user "can edit the message, send the message unedited, or choose not to send the message."

Your server is not involved, and nothing is recorded on your side. The message lives in the visitor's mail client, not in a database you control.

What this costs you is almost nothing to set up and nothing to run. What it costs the visitor is a configured mail client, and it puts your address in the page's markup. There is no field checking, no required fields, and no copy of the message on the site. If the visitor cancels the draft, you never know that they tried.

Use a mailto link when a plain address is enough, and you accept that you cannot see what happened after the click.

A plugin on a CMS

If the site runs on a content management system, a form plugin usually adds the form, the code that receives it, and the sending of the email. The plugin takes over the receiving end, so you do not write that code yourself.

The cost is a dependency chain. The form then depends on the plugin, on the content management system, and on the server those run on. Each of the three is something you keep updated, and each can change behaviour in a way that affects the form. Before you choose a plugin, compare what it stores, whether it keeps a copy of each submission, how it is maintained, and whether it works the same way on every site you run. A plugin that is excellent on one site may need a separate installation and a separate configuration on the next.

This approach fits when the site is already built on a CMS and you are willing to keep that stack updated.

A hosted form service

A hosted form service gives you an address to put in the form's action. The service receives the submission on its own servers, and then delivers the message to you, by email or in its own dashboard. You maintain the form markup and your account with the service. The service maintains the receiving end.

The trade-off is that the visitor's data passes through a third party. Check where that data is stored and what the service's own policy says about it. Compare services on the things that matter to you: how many sites a single account can receive for, how messages are routed between them, and how the price changes once you have more than one site. Pricing changes over time, so read it on the vendor's current page, not in a comparison written earlier.

A hosted service is the option with the least code on your side. The cost is that you depend on the service staying available and on its terms staying acceptable to you.

Your own small server

You can write a small endpoint that accepts a post, checks the fields, and sends the email or writes the message to a database. For one form, the code is short. What you maintain is everything around it: the server it runs on, the mail sending, the defences against spam, the logs, and the updates.

Every site you add then either gets its own endpoint or shares one. That choice decides how much code you own and how many places you have to change when something breaks. This option gives you full control over the data and the behaviour, and it also gives you the most work.

What to check before choosing

Use the same questions for all four options, so the comparison stays fair.

QuestionMailtoCMS pluginHosted serviceOwn server
Who runs the receiving endThe visitor's mail clientYour CMS and the pluginThe serviceYou
What you keep updatedNothingThe plugin and the CMSYour account and the form markupThe endpoint, mail sending, spam defences, logs
Does a copy stay on your sideNoDepends on the pluginDepends on the serviceYou decide
Can you validate fields before sendingNoDepends on the pluginDepends on the serviceYes

Also check these before you commit:

  • Whether you need a record of every submission, or only the email.
  • Who needs access to the messages, and whether that changes per site.
  • What happens to the form and its messages when you retire a site.
  • Whether the approach needs to be set up again on each new site.

Many sites: where one approach per site breaks down

Each of the four options works for one site. Trouble starts when you run several. Suppose one site uses a plugin, a second uses a hosted service, and a third uses a mailto link. You now have three receiving ends, three places to check for errors, and three ways to lose a message without noticing. The same is true for three of the same kind: three plugin installations, three accounts, or three endpoints.

Per-site setups are simple at first and expensive to keep track of later. Decide early whether you want one receiving end for all your sites or one per site, and write that decision down, because it changes every option above.

Prosphere is a form backend and shared inbox for people who run many websites. It is in build, and the approach is described on how it works. If you want to hear when it opens, join the waitlist. The shared inbox page describes the inbox side of the same idea.

Sources

Join the waitlist

Join the Prosphere waitlist for a form backend and shared inbox for many websites, or write to info@prosphere.app. One message when it opens.

Waitlist