DOIfast provides a simple way to add double opt-in verification to any form on your website. Just add one script tag to your page, and we'll handle the rest.
Add the following script to your HTML:
<script>
(function() {
var f = document.createElement('script');
f.type = 'text/javascript';
f.async = true;
f.src = 'https://www.doifast.com/api/forms/YOUR_PROJECT_ID';
f.setAttribute('data-project', 'YOUR_PROJECT_ID');
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(f, s);
})();
</script>
Replace YOUR_PROJECT_ID
with the project ID from your dashboard.
When a user submits a form, our script intercepts the submission and sends a verification email to the provided address.
The user receives a verification email with a unique link. Clicking the link confirms their email address and intent to submit the form.
After verification, we process the original form submission. The form data is sent to your server exactly as if the user had submitted it directly.
You can customize the verification email template in your project settings. Available variables:
{{verificationLink}}
- The verification link{{email}}
- The user's email address{{siteName}}
- Your website nameSet up webhooks in your project settings to receive notifications for:
Yes! Our script automatically works with any HTML form that includes an email field. No modifications to your existing forms are needed.
We preserve any existing form validation. Our script only adds the double opt-in verification step after the form passes your validation.
Yes, our double opt-in system ensures explicit consent and maintains a record of when and how the user verified their email address.