WhatsApp
Chat on WhatsApp

Website Contact Forms: How to Build One That Gets Leads

A form is the main way a website visitor talks to a business. It is where people leave their details, ask for a quote, sign up for a webinar, place an order or simply search the site. When a form works well, nobody thinks about it. When it works badly, the business loses leads and often doesn't even know it.

Anyone who has run a website knows the symptoms: enquiries that never reached the inbox, a form that won't submit on a phone, dozens of spam messages a day, a lead that sat untouched for two days because nobody saw it. Most of these problems can be solved at the planning stage.

In this guide we cover:

  • how a form works behind the scenes and what happens when someone clicks "Send";
  • which fields to include and how to check the data before it is sent;
  • how to make a form accessible and easy to use on a phone and in any language;
  • how to protect a form from spam and meet privacy requirements such as GDPR;
  • how to connect a form to your CRM, messaging apps and analytics.

What a website form is and why it matters so much

Technically, a form is a group of fields and buttons that collects information from the user and sends it to a server. In the site's code it is built with the <form> tag, which wraps all the fields. Visitors never see the tag itself, only the fields and the button, but without it the browser wouldn't know what to do with the data that was typed in.

From a business point of view, the form is the site's conversion point. Everything you invest in design, content, SEO and campaigns comes down to one moment: will the visitor fill in the form or close the tab? That is why a form is not a technical detail to leave to the developer at the end of the project. It is part of your sales funnel.

Small and mid-sized business websites usually have several types of forms:

  • Contact form – name, phone, email and a short message. The most common type, found on the home page, the contact page and landing pages;
  • Quote or brief form – questions about the project, budget, timeline and an attachment;
  • Sign-up form – for a webinar, a newsletter or a lead magnet;
  • Search form – a search bar for the site or the blog;
  • Login form – access to a member area or a customer account;
  • Order and checkout form – in an online shop, usually part of the e-commerce platform.

We covered the structure of a landing page where the form is the main goal in our landing page design guide. Here we focus on the form itself.

How a form works behind the scenes

Even if your site is built on Webflow, WordPress or Wix and the form was dragged in from a panel, it pays to understand what happens inside. It helps you diagnose problems and speak the same language as your developer.

Three attributes that define a form

The <form> tag has three important attributes:

  • action – the address the data is sent to: a server script, a form service or a webhook. If it is not set, the form submits to the same page it lives on;
  • method – how the data is sent. With GET, the data is appended to the page URL, which suits search and filtering because you can share a link to the results. With POST, the data travels in the body of the request and does not appear in the URL. This is the method for any form with personal details, passwords or files;
  • enctype – how the data is encoded. It matters mainly for file uploads: without the value multipart/form-data, the file simply won't be sent.

Keep in mind that POST hides the data from the URL but does not encrypt it. Encryption comes from HTTPS, which is why every site with a form needs a valid SSL certificate.

What happens when someone clicks "Send"

When the user clicks the button, the browser goes through several steps:

  • it collects the values of every field that has a name attribute. A field without a name is not sent at all, even if the user filled it in;
  • it checks the data against the rules set on the fields, such as a required field or an email format;
  • it encodes the data and sends a request to the address in action, using the method in method;
  • it receives the server's response and shows it: a thank-you message, a thank-you page or an error.

On modern sites the submission usually happens in the background, without reloading the page, and the user sees a message in place of the form. The principle stays the same.

A 3D glass form sending glowing envelopes along a path of light to a glossy server, with a check mark travelling back to the form
What happens when you click Send: the data leaves the browser for the server, and the server sends back a response. Illustration: RJL Studio

Which fields to include and how to validate them

Every field in a form is one more obstacle on the way to submission. The simple rule: ask only for what you really need to get back to the person at this stage. Everything else can wait for the first conversation.

The main field types

  • Input field (input) – the basis of every form. Its type is set by the type attribute: text for a name, email for an email address, tel for a phone number, number for numbers, date for dates, checkbox for a tick box, radio for picking one option out of several, file for uploads;
  • Text area (textarea) – for a free-form message, a project description or feedback;
  • Dropdown (select) – for choosing from a known list, such as the type of service or a budget range;
  • Button (button) – submits the form.

Choosing the right field type saves a lot of frustration on mobile. A tel field brings up a numeric keypad, and an email field shows a keyboard with the @ sign. The autocomplete attribute, with values such as name, email and tel, lets the browser fill in details automatically and cuts form completion down to seconds.

How many fields is too many

For a standard contact form, a name, a phone number or email address, and an optional message are enough. Which contact detail matters most depends on how you follow up: if your team calls or messages leads back, make the phone the key field; if you work mostly by email, put email first and make the phone optional. If you need detailed information, for example in a project brief, split the form into steps: contact details first, then questions about the project. Even if the user drops off halfway, you already have the basics.

Validation: checking data before it is sent

Validation means checking that the data is correct before it is sent. HTML has built-in checks that work without a single line of JavaScript:

  • required – a mandatory field. The form cannot be submitted while it is empty;
  • type – the browser checks that an email looks like an email and a number is a number;
  • pattern – a rule written as a regular expression, for example a phone number made up of digits, spaces and an optional leading plus sign;
  • minlength and maxlength – the minimum and maximum length of a text.

If you want your own error messages, in your language and in a human tone, add a check in JavaScript. But the most important rule is this: browser validation is a convenience for the user, not protection. Every check must be repeated on the server, because a bot or a determined user can send data without ever going through the form.

A few rules for error messages:

  • show the error next to the field, not only at the top of the form;
  • say what to fix, not just that something is wrong: "The phone number should contain at least 9 digits" instead of "Invalid field";
  • never wipe what the user has already typed;
  • don't be too strict: a number with spaces, dashes or an international prefix such as +351 is still a valid phone number.
A glass form panel with fields of different shapes, a checkbox, a dropdown and a button; a green check mark sits next to the top field and another field is outlined with an orange error frame
Different field types and checking the data before it is sent. Illustration: RJL Studio

Form accessibility: a legal requirement and good business

A form has to work for people who use a screen reader, navigate only with a keyboard or zoom in on text. In the EU this is increasingly a legal matter too: the European Accessibility Act has applied since June 2025 to many consumer-facing digital services, including online shops, and the related standards are built on WCAG at level AA. Accessibility audits often start with forms, because that is where problems are most visible. We go deeper into the topic in our website accessibility guide. This is not legal advice: whether the rules apply to your business depends on your sector and size.

What an accessible form must have

  • A label for every field, linked to the field through the for and id attributes. That way a screen reader announces what to enter, and clicking the label moves the cursor into the field;
  • Don't rely on a placeholder alone. The grey text inside the field disappears as soon as you start typing, and its contrast is usually too low;
  • Group related fields with a fieldset and a legend, for example a set of radio buttons for "How should we contact you?";
  • Error messages linked to the field through aria-describedby, so the screen reader reads them out;
  • Logical keyboard order. The Tab key should move between fields in the order they appear on screen. Avoid artificial tabindex values;
  • A clear focus outline, so keyboard users can see where they are;
  • Sufficient contrast between the text, the field borders and the background.

A quick test you can do yourself

Try filling in your form without a mouse, using only Tab, Space and Enter. If you get stuck, lose track of the cursor or can't tick a box, users with disabilities will get stuck too.

A glossy 3D keyboard in front of a glass form where one field has a glowing orange focus outline and an arrow points to the next field, with headphones beside it representing a screen reader
An accessible form works with a keyboard and with a screen reader. Illustration: RJL Studio

Form design that converts: UX on mobile and across languages

A good form looks simple, but there are many small decisions behind it. Here are the ones that affect conversion the most.

Structure and layout

  • One column. The eye moves from top to bottom, and fields placed in two columns tend to get missed, especially on a phone;
  • Label above the field, not beside it. The form is easier to scan and fits any screen width;
  • Fields big enough for a finger, with space between them;
  • A button that describes the outcome: "Get a quote" or "Send and we'll reply today" work better than "Submit", because they remind the user what they get.

Multilingual sites and right-to-left languages

If your site runs in more than one language, there are a few things that are easy to miss:

  • each language version needs its own form, field labels, error messages and thank-you page in that language, not a mix;
  • the browser's built-in validation messages appear in the browser's language, so a visitor with an English browser on your Portuguese page will see English messages. If you want everything in one language, write your own messages;
  • in right-to-left languages the form runs from right to left, but email, phone and URL fields should still be displayed left to right, otherwise characters get jumbled and it is hard to check what was typed;
  • phone fields should accept international formats, because your visitors may not all be in one country.

What happens after submission

The moment after the click matters as much as the form itself. The user must see straight away that the enquiry was received: a clear message in place of the form, or a thank-you page. Say what happens next and when, for example "We'll get back to you within one business day", and offer a next step: a link to a messaging app, your portfolio or a relevant article. A separate thank-you page is also handy for analytics, because it is easy to count how many times people reached it.

Spam protection and privacy: what you need to know

Every public form gets spam. Bots crawl the web and fill in every form they find. At the same time, every form collects personal data, which makes it a legal matter as well.

How to protect a form from bots

  • Honeypot field – a hidden field that a real user never sees or fills in. A bot fills it in, and the server filters the submission out. Completely invisible to users;
  • Google reCAPTCHA – newer versions check behaviour in the background and rarely ask people to click on traffic lights;
  • Cloudflare Turnstile – an alternative that usually requires no action from the user;
  • Rate limiting – blocking an address that sends dozens of submissions within a few minutes;
  • Built-in platform filtering – Webflow, Wix and the major WordPress form plugins have built-in protection, so make sure it is switched on.

Start with the invisible methods. A challenge the user has to solve hurts conversion and sometimes accessibility as well.

Privacy and marketing consent

  • Personal data is protected. In the EU, the GDPR governs how businesses collect and handle personal data, and a contact form is personal data collection. Collect only what you need, store it securely, limit who can access it and decide how long you keep it;
  • Privacy policy. Place a link to your privacy policy next to the form, explaining what data is collected, for what purpose and who it is shared with;
  • Separate marketing consent. Under EU ePrivacy rules and the GDPR, sending marketing messages by email or SMS generally requires the person's prior consent. Submitting a contact form is therefore not consent to your newsletter. You need a separate checkbox that is not ticked in advance;
  • Attachments. If the form accepts files, restrict the type and size with the accept attribute and on the server, and check where the files are stored.

This is not legal advice. Rules differ between countries, and if you collect sensitive data, such as health or financial information, talk to a lawyer who specialises in data protection.

A glowing glass shield standing in front of a 3D form and stopping small robots, while a faceless white figure walks past it to a form with an orange padlock
Keeping bots out and protecting your customers' personal data. Illustration: RJL Studio

Where the lead goes: CRM, messaging and analytics

A form that only sends enquiries to a shared inbox is a single point of failure. Emails land in spam, get buried in the inbox or go to someone who is on holiday. The fix is to connect the form directly to the systems your business actually works in.

Where to build the form

  • Webflow – has a native form element: submissions are stored in the site settings, sent by email and can be passed on via webhook to any other system. This is how forms work on the sites we build in Webflow;
  • WordPress – plugins such as Contact Form 7, WPForms, Gravity Forms, Fluent Forms or Elementor forms. Pick a plugin that is updated regularly and avoid running several form plugins at once;
  • Wix – the built-in Wix Forms element, connected to the Wix CRM and the platform's automations;
  • External form services – Typeform, Tally, Jotform or Google Forms. Handy for surveys and questionnaires, but for the main form on your site a native element is better: it looks like the rest of the site and is easier to track.

Connecting to a CRM and messaging apps

A typical setup looks like this: a visitor fills in the form, a lead is created automatically in the CRM with its traffic source, the sales rep gets an alert in WhatsApp, Slack or Telegram, and the customer receives a confirmation message. You can build all of this without custom development using n8n, Make or Zapier. The form sends its data to a webhook, and the workflow distributes it to the other systems. We explain how this works in our n8n automation guide.

Store the UTM parameters and the page the form was submitted from with every lead. Without them, you can't tell which campaign brought in customers and which one just burned budget.

Tracking

  • Google Analytics 4 – enhanced measurement can record form_start and form_submit events automatically, but it isn't always accurate, especially for forms that submit in the background. It is more reliable to send a generate_lead event only after a successful submission and mark it as a key event;
  • Meta Pixel and Conversions API – a Lead event after a successful submission, so your Facebook and Instagram campaigns learn from the people who actually left their details. Respect your cookie consent settings when firing these tags;
  • Regular checks – once a month, send a test enquiry and confirm it reached every destination: email, CRM, alerts and analytics.
A floating glass form with turquoise and purple light pipes running to a CRM board with lead cards, a chat bubble and a glowing bar chart
An enquiry from the form flows automatically into the CRM, a chat alert and your analytics. Illustration: RJL Studio

Common website form mistakes

These are the problems we see most often when we review existing websites:

  • A field without a name – the user filled it in, but the data went nowhere;
  • GET for a form with personal details – the name and phone number end up in the URL, the browser history and the server logs;
  • File uploads without the right enctype – the form is sent, the file isn't;
  • Fields without labels – only a placeholder, which disappears and isn't read by screen readers;
  • Too many required fields – for example, a full postal address when all you need is to call back;
  • Browser-only validation – bots bypass it easily;
  • Enquiries that only go to email – no backup, no CRM, no alert;
  • No clear thank-you message – the user isn't sure the enquiry was sent, so they send it again or give up;
  • A pre-ticked newsletter box – damages trust and doesn't meet the requirement for clear, active consent;
  • Nobody tests the form – after a template, plugin or domain update the form breaks, and you only notice when the leads dry up.

A short pre-launch checklist

  • send a test enquiry from a computer and from a phone, and check it reached every destination;
  • fill in the form using only the keyboard;
  • try to submit an empty form and invalid fields, and check that the messages are clear and in the right language;
  • make sure the site runs on HTTPS and there is a link to the privacy policy;
  • check that conversion events are recorded in GA4 and Meta;
  • confirm that spam protection is active and doesn't block real users.

How RJL Studio builds forms that don't lose leads

We plan the form together with the page and the sales process, not as an add-on at the end. On every project we define which fields are really needed, build a form that is accessible and comfortable on mobile and in every language of the site, add invisible spam protection, and connect it to your CRM, to alerts in WhatsApp, Slack or Telegram, and to conversion events in GA4 and Meta. When you need a more complex process, such as routing leads between sales reps, automated follow-up messages or syncing with your invoicing system, we build it as part of our automation and integrations service.

Does your website's form bring in too few enquiries, or do leads get lost along the way? Get in touch and we'll work out together where the lead gets stuck and how to close the gap.

Frequently asked questions

How many fields should a contact form have?

As few as possible. Usually a name, a phone number or email address, and an optional message are enough. Every extra field lowers the chance that the form gets submitted. If you need detailed information, split the form into steps or save the questions for the first call.

What is the difference between GET and POST in a form?

With GET, the data is appended to the page URL, which suits search and filtering. With POST, the data is sent in the body of the request and isn't visible in the URL, which is the method for any form with personal details or files. In both cases encryption comes from HTTPS, not from the submission method.

Why aren't form submissions reaching me?

The usual reasons: the email lands in the spam folder, the recipient address in the form settings is wrong, a field is missing its name, the form plugin was updated and broke, or the spam protection is also blocking real enquiries. Send a test enquiry, check the submissions list in the platform itself, and ideally connect the form to a CRM as well, not just to email.

Can form submissions go straight to WhatsApp?

Yes. Through n8n, Make or Zapier, the form can send an alert to a sales rep's WhatsApp, create a lead in the CRM and send the customer a confirmation. Automated WhatsApp messages require the WhatsApp Business Platform through an approved provider, and marketing messages require the customer's explicit consent.

Does reCAPTCHA hurt conversions?

Versions that show a challenge, such as picking images, hurt usability and sometimes accessibility. Versions that check in the background, as well as Cloudflare Turnstile and honeypot fields, are barely noticeable. Start with the invisible methods and add a challenge only if spam keeps coming.

Disclaimer: blog content is for general information and learning only and is accurate as of its publication date. It is not professional, legal, financial or business advice, nor a recommendation or call to take any action. Any use of this information is at the reader's own risk, and we accept no liability for any resulting loss. Links to external websites and tools are provided for convenience only. We recommend consulting a qualified professional before making decisions.