Web3Forms
Search…
Installation

Step 01: Get Access Key

First step is to get an Access Key from Web3Forms. Create Access Key​
Once you submit the form, you will get the Access key in your Email. Copy that key so that we can use this later.

Step 2: Create HTML Form

Create a form in your website with our form endpoint inside action attribute. Following is a simple example on how it should look like:
Basic Example
Advanced Example
1
<form action="https://api.web3forms.com/submit" method="POST">
2
​
3
<input type="hidden" name="access_key" value="YOUR_ACCESS_KEY_HERE">
4
​
5
<input type="text" name="name" required>
6
<input type="email" name="email" required>
7
<textarea name="message" required></textarea>
8
<input type="hidden" name="redirect" value="https://web3forms.com/success">
9
<button type="submit">Submit Form</button>
10
​
11
</form>
Copied!
1
<form action="https://api.web3forms.com/submit" method="POST">
2
​
3
<!-- REQUIRED: Your Access key here. Don't worry this can be public -->
4
<!-- Create your Access key here: https://web3forms.com/ -->
5
<!-- <input type="hidden" name="apikey" value="YOUR_ACCESS_KEY_HERE"> -->
6
<input type="hidden" name="access_key" value="YOUR_ACCESS_KEY_HERE">
7
​
8
<!-- Optional: Can be type="hidden" or type="text" for subject -->
9
<input type="hidden" name="subject" value="New Submission from Web3Forms">
10
11
<!-- Optional: From Name you want to see in the email
12
Default is "Notifications". you can overwrite here -->
13
<input type="hidden" name="from_name" value="Your Website Name">
14
15
<!-- Optional: To send the form submission as CC email -->
16
<input type="hidden" name="ccemail" value="[email protected]">
17
​
18
<!-- Optional: default replyto will be "email" (if available),
19
you may overwrite here -->
20
<input type="hidden" name="replyto" value="[email protected]">
21
​
22
<!-- Required: if submitting without Javascript
23
(because by default web3form outputs json) -->
24
​
25
<!-- If javascript, use "window.location.hash" for redirects -->
26
<input type="hidden" name="redirect" value="https://web3forms.com/success">
27
​
28
<!-- Optional: But Recommended: To Prevent SPAM Submission.
29
Make sure its hidden by default -->
30
<input type="checkbox" name="botcheck" id="" style="display: none;">
31
32
<!-- Webhooks: Send your form data to Notion, Google Sheets or Zapier.
33
This feature available to PRO & Starter Plan users only -->
34
<input type="hidden" name="webhook" value="WEBHOOK_URL_HERE" />
35
​
36
<!-- Google reCaptcha v3: To Prevent SPAM Submission.PRO Plan only -->
37
<input type="hidden" name="recaptcha_response" id="recaptchaResponse">
38
39
<!-- Attachments: Make sure the <form> has enctype="multipart/form-data"
40
This feature available to PRO Plan users only -->
41
<input type="file" name="attachment" />
42
​
43
<!-- Custom Form Data:
44
Then you can include your own form data you wish to receive in email. -->
45
<input type="email" name="email" required>
46
<input type="text" name="First Name" required>
47
<input type="text" name="Phone Number" required>
48
<textarea name="message" cols="30" rows="10" required></textarea>
49
​
50
<button type="submit">Submit Form</button>
51
​
52
</form>
Copied!
Make sure you added `name` attribute, form action URL and the `access_key` to make the form work as expected

Step 3: Add your Access Key

Add your access key to start receiving email submissions.
1
<input type="hidden" name="apikey" value="YOUR_ACCESS_KEY_HERE">
Copied!

Step 4: Done

That's it. Run your code on a browser and it should work. This is a simple starting example. However you can customize it with unlimited possibilities. Checkout other pages to know more.