A comprehensive contact form plugin for Craft CMS that combines the functionality of the official Contact Form plugin with enhanced features like database storage, confirmation emails, template overrides, and reCAPTCHA support.
- Send contact form submissions via email
- Support for file attachments
- Configurable email templates
- Form validation
- Flash message notifications
- Database Storage: Save all form submissions to the database for viewing in the Control Panel
- Confirmation Emails: Send automatic confirmation emails to form submitters
- Template Overrides: Use custom email templates for notifications and confirmations
- reCAPTCHA Support: Protect forms from spam with reCAPTCHA v2 (invisible) or v3
- Form Management: View and manage all submissions through the Control Panel
- Multi-form Support: Support for multiple forms with different names
- Copy this plugin to your
plugins/directory - Install via Composer:
composer require hybridinteractive/simple-contact-form
- Install the plugin in the Craft CMS Control Panel
- To Email: The email address(es) that form submissions will be sent to
- Sender Text: Text prepended to the "From" name in emails
- Subject Text: Text prepended to email subjects
- Allow Attachments: Enable/disable file upload support
- Success Flash Message: Message shown after successful form submission
- Save submissions to database: Enable to store all submissions in the database for viewing in the Control Panel
- Enable template overwrite: Allow custom email templates
- Notification Template: Custom template for notification emails
- Enable confirmation emails: Send confirmation emails to form submitters
- Confirmation Template: Custom template for confirmation emails
- Confirmation Subject: Subject line for confirmation emails
- Enable reCAPTCHA: Protect forms from spam
- reCAPTCHA Version: Choose between v2 (invisible) or v3
- Site Key & Secret Key: Your reCAPTCHA keys from Google
- Threshold: Minimum score for reCAPTCHA v3 (0.0 to 1.0)
- Hide Badge: Hide the reCAPTCHA badge
<form method="post" accept-charset="UTF-8">
{{ csrfInput() }}
{{ actionInput('simple-contact-form/send') }}
<input type="text" name="fromName" value="{{ message.fromName ?? '' }}" placeholder="Your Name">
<input type="email" name="fromEmail" value="{{ message.fromEmail ?? '' }}" placeholder="Your Email">
<input type="text" name="subject" value="{{ message.subject ?? '' }}" placeholder="Subject">
<textarea name="message[body]" placeholder="Your Message">{{ message.message.body ?? '' }}</textarea>
<button type="submit">Send Message</button>
</form><form method="post" accept-charset="UTF-8">
{{ csrfInput() }}
{{ actionInput('simple-contact-form/send') }}
<input type="text" name="fromName" value="{{ message.fromName ?? '' }}" placeholder="Your Name">
<input type="email" name="fromEmail" value="{{ message.fromEmail ?? '' }}" placeholder="Your Email">
<input type="text" name="subject" value="{{ message.subject ?? '' }}" placeholder="Subject">
<textarea name="message[body]" placeholder="Your Message">{{ message.message.body ?? '' }}</textarea>
{{ craft.simpleContactForm.recaptcha() |raw }}
<button type="submit">Send Message</button>
</form><form method="post" accept-charset="UTF-8">
{{ csrfInput() }}
{{ actionInput('simple-contact-form/send') }}
<input type="text" name="fromName" value="{{ message.fromName ?? '' }}" placeholder="Your Name">
<input type="email" name="fromEmail" value="{{ message.fromEmail ?? '' }}" placeholder="Your Email">
<input type="text" name="subject" value="{{ message.subject ?? '' }}" placeholder="Subject">
<textarea name="message[body]" placeholder="Your Message">{{ message.message.body ?? '' }}</textarea>
{{ craft.simpleContactForm.recaptcha('contact') |raw }}
<button type="submit">Send Message</button>
</form><input type="hidden" name="message[formName]" value="support"><input type="hidden" name="message[notificationTemplate]" value="{{ 'custom-notification'|hash }}">
<input type="hidden" name="message[confirmationTemplate]" value="{{ 'custom-confirmation'|hash }}"><input type="hidden" name="message[disableRecaptcha]" value="true">
<input type="hidden" name="message[disableSaveSubmission]" value="true">
<input type="hidden" name="message[disableConfirmation]" value="true">{% for submission in craft.simpleContactForm.submissions %}
<p>{{ submission.dateCreated|date('d-m-Y H:i') }} - {{ submission.fromEmail }} - {{ submission.fromName }}</p>
{% endfor %}{% if craft.simpleContactForm.settings.enableDatabase %}
<p>Database storage is enabled</p>
{% endif %}- Craft CMS 5.0.0 or later
- PHP 8.2 or later
MIT
This plugin combines functionality from:
- Craft CMS Contact Form by Pixel & Tonic
- Craft Contact Form Extensions by Hybrid Interactive
If you find this plugin useful, consider buying us a coffee.