How to Set Up a Web3Forms Contact Form on Your Website
Updated
To connect a contact form to Web3Forms, create a form to get an access key, then point your HTML form at https://api.web3forms.com/submit with a hidden access_key field. No server or backend code is required, and the free tier covers 250 submissions per month.
Prerequisites
- A working HTML form (or the ability to add one to your site).
- An email address you can verify, since the access key is tied to it.
- No credit card is required to start on the free plan, per the site.
Step 1: Create your form and get an access key
- Go to web3forms.com and use the "Create your Form" flow.
- Sign up and verify your email address.
- Copy the access key shown after verification. This key identifies where submissions are delivered.
The site states the free tier is 250 submissions/month, "free forever," with an upgrade path as volume grows.
Step 2: Add the form markup
Paste this into your page and replace YOUR_ACCESS_KEY_HERE with your key:
<form action="https://api.web3forms.com/submit" method="POST">
<input type="hidden" name="access_key" value="YOUR_ACCESS_KEY_HERE">
<input type="text" name="name" required>
<input type="email" name="email" required>
<textarea name="message" required></textarea>
<button type="submit">Submit Form</button>
</form>
What each part does:
actionsends the submission to the Web3Forms endpoint.method="POST"is required for the endpoint to accept the data.- The hidden
access_keyinput routes the submission to your verified email. - Named fields (
name,email,message) become the content of the email you receive.
Step 3: Test and verify
- Open the page in a browser and submit a test entry.
- Check the inbox tied to your access key for the message.
- If nothing arrives, confirm the key value is exact, the form uses POST, and the hidden field is present.
Step 4: Adapt to your stack
The site provides copy-ready examples for HTML, JavaScript, and React under its docs. For JavaScript or React, keep the same endpoint and access key, and submit the field values as form data. The service is API-based, so it can be styled to match any design.
What happens to submissions
- Emails are sent directly to your address.
- Submissions are transmitted over HTTPS and encrypted at rest.
- Form submissions are stored for up to 3 years, with a retention period you control.
- The site states GDPR compliance and that data is not shared or sold to third parties.
Common snags
| Symptom | Likely cause | Fix |
|---|---|---|
| No email received | Wrong or missing access_key |
Re-copy the key from your account |
| Form does nothing | action or method incorrect |
Use the exact endpoint and POST |
| Fields missing in email | Inputs lack name attributes |
Add name to each field |
| Spam in inbox | No filtering configured | The site reports spam blocking; review its options |
When this fits
Use Web3Forms if you want a static-site or no-backend contact form that emails you directly and you expect volume within the free tier. If you need custom server-side processing or storage beyond the stated retention, plan for the paid tier or a different backend.