This post is no longer updated. Move to Contact Form 7 official site.
Download | Plugin Homepage | FAQ | Support Forum
Summary
![]()
Just another contact form plugin. Simple but flexible.
- Supports multiple contact forms.
- You can customize form and mail contents with simple markup.
- AJAX submitting with jQuery Form Plugin.
- Spam filtering with Akismet.
- Bot prevention with CAPTCHA.
Download and Install
Download the latest release from WordPress.org plugin directory.
- Upload whole contact-form-7 folder to the /wp-content/plugins/ directory
- Activate the plugin through the ‘Plugins’ menu in WordPress
Usage
- Open admin page
[Options] – [Contact Form 7][Manage] – [Contact Form 7].Update: If you are using WordPress 2.7 or greater, you can find the admin page under [Tools] – [Contact Form 7].
- Edit default “Contact form 1” or add new and save it.
- Copy
[contact-form ...]code and paste it into the content of any posts you need the contact form.
FAQ
How to customize form and mail contents
You can use “tags” in several fields. Contact Form 7’s “tag” is formed string enclosed in square brackets [].
A tag used in form content is replaced by HTML form control element like <input> or <textarea>.
A tag used in mail template is replaced by user input of element with the same name.

In this picture, a tag [textarea your-message ...] inserted in form content is replaced by <textarea> tag with name="your-message" attribute.
When a visitor input into this <textarea> field and submit, Contact Form 7 generates a mail based on mail template. Since message body field has [your-message] tag, this tag replaced by the user input message.
Tags in form content
You can use the following types of tags in form content.
| Type | Replaced by | Validated as |
|---|---|---|
| text | <input type="text" /> |
Any text |
| text* | <input type="text" /> |
Any text / Required |
<input type="text" /> |
Email address | |
| email* | <input type="text" /> |
Email address / Required |
| textarea | <textarea> </textarea> |
Any text |
| textarea* | <textarea> </textarea> |
Any text / Required |
| select | <select> </select> |
— |
<select> </select> |
— | |
| checkbox | <input type="checkbox" /> ... |
— |
<input type="checkbox" /> ... |
— | |
| radio | <input type="radio" /> ... |
— |
| captchac | <img /> |
CAPTCHA See How to use CAPTCHA |
| captchar | <input type="text" /> |
|
| submit | <input type="submit" /> |
— |

The syntax of tag is not so easy. You can use Generate Tag menu under Form textarea to make a tag you need.
I show you some examples of tags.
[text your-name 40/100 "John Smith"]This tag is replaced with:
<input type="text" name="your-name" size="40" maxlength="100" value="John Smith" />[email* your-email 60/ id:email]<input type="text" name="your-email" id="email" size="60" />[textarea your-message 80x15 "Write message here."]<textarea name="your-message" cols="80" rows="15">Write message here.</textarea>
[select your-country "China" "India" "other"]<select name="your-country"> <option value="China">China</option> <option value="India">India</option> <option value="other">other</option> </select>
I wrote about tag syntax.
How to use Akismet on Contact Form 7
1. You need Akismet plugin. If you have not activated it yet, activate it first.
2. Open Contact Form 7’s admin page and edit Form text area as:
- Add
akismet:authoroption to the tag of field which requires sender’s name.
Example:[text* your-name akismet:author] - Add
akismet:author_emailoption to the tag of field which requires sender’s email address.
Example:[email* your-email akismet:author_email] - Add
akismet:author_urloption to the tag of field which requires sender’s URL.
Example:[text your-url akismet:author_url]
Once you have activated the Akismet plugin and at least one of the akismet: options is set, Contact Form 7 will send all of a sender’s input as well as any other information related to input activity to the Akismet server. Akismet will then judge whether this input is likely to be spam.
When Akismet judges a message as spam, Contact Form 7 sends no mail and shows a response message with an orange border line (the third example in the picture below).

To make sure the spam filtering is working, send a message with “viagra-test-123” as the sender’s name. If the test is a success, the message will be judged as spam.
Changelog
- 0.9 (2007/04/30)
- Initial release.
- 1.0 (2007/05/20)
- Tag helper.
- 1.1 (2007/08/02)
- File restructuring.
- 1.2 (2007/08/16)
- jQuery Form Plugin introduced.
- 1.3 (2007/08/26)
-
New tag type:
[select] - 1.3.1 (2007/08/26)
- Critical bug about JavaScript loading fixed.
- 1.3.2 (2007/09/03)
- Bug fix around jQuery.
- 1.4 (2007/09/07)
- Akismet spam filtering introduced.
- 1.4.1 (2007/09/11)
- Add Spanish and Catalan translations.
- 1.4.2 (2007/09/13)
- Add German translation.
- 1.4.3 (2007/09/15)
- Add Polish translation.
- 1.4.4 (2007/09/17)
- Add French translation.
- 1.5 (2007/10/07)
- CAPTCHA introduced.
- 1.6 (2007/10/17)
- Mail (2) and UI improvement for admin page.
- 1.6.1 (2007/10/27)
- Sidebar widget support.
- 1.7 (2007/11/27)
-
New tag type:
[select+],[checkbox],[checkbox+]and[radio] - 1.7.1 (2007/12/06)
- Made wpcf7 variable global. Polish translation updated.
- 1.7.2 (2007/12/13)
- Bugfix. Czech translation added.
- 1.7.3 (2007/12/23)
- New
default:andlabel-firstoptions added. - 1.7.4 (2007/12/30)
select+andcheckbox+tag types removed.multipleandexclusiveoptions added.- 1.7.5 (2008/01/26)
- Two fixes and
include_blankoption. - 1.7.6 (2008/03/02)
- New
acceptancetag added.
1,401 replies on “Contact Form 7”
I also have problems using the form together with akismet. When I activate the option it hangs when trying to send the mail. Without akismet everything is working perfectly. Any ideas??
thx
Vicente
Vicente,
I have no clue. It might be that Akismet server was tired.
Hi, i’ve got a problem with the input fields on my contact page – they’re aligned to the left. Is there something in the style sheet i should change to make them flush, or is it a theme issue?
Thanks.
Dominic,
You can customize it from the stylesheet in the theme you’re using or from contact-form-7/stylesheet.css
Ok, i’ll have a look. Thanks for the quick response.
[…] Contact Form 7 = nice contact form for your users to contact you […]
ok, I’ve been all through this site and I can’t figure out how to add additional fields either using the generate tag function. does this mean I can only have the email | subject | text with this plugin…or can I add more fields like textarea, radial button, checkbox all in one? I can generate the code but my received emails upon test Never have anything but email | subject | text …
Hi, it turns out the problem I was experiencing with the alignment was an Internet Explorer issue. It works fine with Firefox.
Thanks for your help, the contact form is great!
27ragbag:
in the message body of the first Mail box, add [radio-xxx], [select menu-xxx], or whatever the generated code said.
27ragbag,
Let’s see into your Mail field set. You’ll find [your-name], [your-email], [your-subject] and [your-message], they are corresponding to [text* your-name], [email* your-email], [text your-subject] and [textarea your-message] respectively in upper Form field.
[your-name] tag in mail will be replaced by user input through text input field of [text* your-name], likewise [your-email], [your-subject] and [your-message] will.
After generating a tag by the generate tag function, you have to 1) insert the tag into Form field and 2) insert corresponding [(name-of-the-tag)] into wherever in Mail field set you want to use.
hi
i have install the plugin works perfect !
1 thing is that i didn’t understand how to make the captcha filed as a text and also to make it as a must filed???
pleazse help me with that.
also i will sit on this plug to translate into hebrew.
this is a link to the page that i create:
http://www.pintophotography.com/wp/?page_id=67
Thanks,
Pinto.
I installed the plugin fine, the captcha works, and I get emails sent.
But the one thing that doesn’t come through are the checkbox selections! It just sends me the code for them. I get the user message, etc. without fail. What am I doing wrong?
I didn’t see this mentioned in any of the comments above. Thanks in advance
Pinto,
See this page. Just pairing
[captchac]and[captchar].Thank you! Can I include it into next release? (but your link is not working currently.. any trouble?)
randy,
This may help you. If there is no form tag sharing the same name (in the picture, ‘your-message’ is their name) with mail tag, the mail tag is output without being replaced, like you are seeing.
Hi Miyoshi,
Can you help me in CAPTCHA, Im hosting in Hostmonster. theres a error in line 60 in captcha.php. In my localhost it works fine. Can you help me man!
Big Thanks,
Jonathan Concepcion
the link is ok i just put this page as not show until i will figured it out to work good!
and yes you can put it in the next release,
i will work on it hopefully this week i just transfer my website now to a new hosting company so i will let you know…
p.s.
i still don’t know how to make the captcha to work.
plus when i get the email from the blog the subject not show, and the drop down menu i created not show in the message any suggestion ?
Jonathan Concepcion,
Yes, imagettftext() used in line 60 needs GD and FreeType libraries to work. It seems that Hostmonster doesn’t support them. You should ask Hostmonster’s support or use other server.
mp26,
This section explains the basic usage of Contact Form 7’s tag. Please read it if you have not yet. A tag in Mail fields, like in subject, is replaced with sender’s input through a tag in Form textarea with the same name. If there is no tag with the same name, it is not replaced and output the tag with no change. So when your drop down menu is
[select foobar "a" "b" "c"], you have to put[foobar]in the Message body textarea in Mail to put user’s choice in the message body. And, about captcha, what problem do you have?Hi! Great plugin! Handles Swedish characters correctly unlike the contact form I first tried…
Quick question: I don’t want to input field to use bold font (see http://www.jimisola.com/contact) – how do I change this? FYI, it’s bold for “Your Name (required)”, “Your Email (required)” and “Subject” but not “Your Message”.
Hello,
I am unable to create a acceptance or checkbox option that works.
When I put in an acceptance into the form…
First Name
[acceptance FirstName]
…it shows a box to check on the web page, but when I check it and hit submit, it says to please check the box to accept. I know you can make it so that it is opposite, so I tried not checking the box and it still says to please check the box to accept.
When I do a checkbox in the form, a checkbox doesn’t even show up on the site.
First Name
[checkbox FirstName]
What I want is to have someone agree to terms. Can you please help? Right now I just have it where it is a required text and they have to write yes in the text area to agree to the terms and that is so not cool:)
Here is the website where the form is…
http://www.sweetspothousing.com/?page_id=5
Thanks!
Hi Miyoshi,
Is there other way to secure contact form 7 and how to use the check box for CC? :D
Hey man check this http://jonathanconcepcion.com/about#credits and http://jonathanconcepcion.com/contact thats the link where I credit you and where the form is.
thanks man more power!
mp26,
This section explains the basic usage of Contact Form 7’s tag. Please read it if you have not yet. A tag in Mail fields, like in subject, is replaced with sender’s input through a tag in Form textarea with the same name. If there is no tag with the same name, it is not replaced and output the tag with no change. So when your drop down menu is [select foobar “a” “b” “c”], you have to put [foobar] in the Message body textarea in Mail to put user’s choice in the message body. And, about captcha, what problem do you have?
=====================================================
wow to much info lol
About the captcha i don’t have a field to punch the captcha id in it, so every one can skip it…
Hi Miyoshi,
Great plugin, and everything seems to work fine, but when i sheck my email, the filled in forms dont show up in the email. The only text that show up is the text that i wrote in the Mail to (Form:… and Message body:…)
any idea what im doing wrong
thanx
knabbel
Hello..
I’m trying use your contact form plugin but always i’ve getting red border with message.
“Failed to send your message. Please try later or contact administrator by other way.”
My server don’t allow me to use mail() function so i have “ShiftThis.net | Swift SMTP” plugin..
is there any solution?
Regards.
Jimisola,
It’s just because of your stylesheet. Insert below and it’ll fix the problem.
input { font-weight: normal }rayhen,
I saw the contact form you’re using (it’s the biggest contact form I’ve seen ever!). I’m not sure, but I guess the cause of the problem is JavaScript error. You should check your site with Firebug. I saw a “syntax error”. It must be one of the cause.
Jonathan Concepcion,
Thank you!
You can also use Akismet for anti spam. Contact Form 7 does not support “the check box for CC”, but you can do the same thing with Mail (2) function. Try it. It’s in the bottom of the admin panel.
mp26,
You can do it just by doing as this instruction explains. Please do it first and tell me how it not work in detail if it doesn’t work.
knabbel82,
Here is an instruction. Use the same name both in form tag and in mail tag.
xONE,
Contact form 7 does not use
mail()directly, so it should work if Swift SMTP works fine. Check if Swift SMTP is really working.[…] søppel. Hvis du ønsker å gi leserene mulighet til å sende deg en epost kan det gjøres med feks contact form 7 (jeg bruker min egen norske oversettelse til det innstikket) eller wp contact form III hos […]
Miyoshi,
Thank you for reply.
Swift SMTP is working fine (I’ve got test email) and I have found confilct with Maintenance Mode plugin.
Now i don’t have message in red border but when i want send email, arrows near send button show up and that’s all..
I was trying with disabled all plugins, only Swift SMTP and Contact Form 7 was enabled.. I have WordPress 2.3.3.
Regards, X
xONE,
Can I see the problematic contact form page? Sometimes JavaScript conflict causes such problem. Can I test on your site?
Miyoshi,
This is a grat plugin. Thanks for it. But I have 2 questions.
I read all of your instructions, and I want to add 2 custom fields in my contact form: url and phone number. I added them and they can be seen on the contact form, however I can’t find a way to include those new fields in the mail, that the plugin sends to me. The plugin sends only the initial fields: name, e-mail, subject and message, but does not includes url and phone number. How do I include them?
I also have Akismet instaled and activated, but when I follow your instructions to activate spam protection on this contact form, and I test it with Vi**ra and other words it still sends the mail. I am running wordpress 2.3.3. What I am doing wrong?
Thanks
Veronique,
To insert into mail, you have to place
[name]tag into Mail fields, like default[your-name],[your-email],[your-subject]and[your-message]. name is the second word in a tag used in Form textarea. So when you use[text foo]in your Form, place[foo]anywhere in your Mail fields.Sorry about this poor documentation… I got the same question three times this week… I must write better documentation soon.
About Akismet, you should confirm Akismet is correctly working for comments first. I don’t know about the inside of Akismet implementation, but Akismet doc says you can use “viagra-test-123” for testing.
Miyoshi,
My blog contact form is located at http://x01devel.ovh.org/?page_id=10 , do you need admin access?
Regards, X
xONE,
I tested on your site and confirmed the problem. It seems something wrong is occurring on server side. I suggest you checking the mail log on your server. There may be a clue.
Hi,
Thanks for your reply about my problem in captcha and the CC.
Cheers!
Jonathan Concepcion
Miyoshi,
I can’t find why Swift SMTP by ShiftThis don’t work on my server but by fortune I’ve found Cimy Swift SMTP ( here is link if someone will need http://www.cimatti.it/blog/cimy-wordpress-plugins/cimy-swift-smtp/)
Now is working perfect!
Many thanks for your plugin :D
All I have to say is wow and thank you. Never have I seen such an easy, beautiful plugin. I used it for a multi-lingual website and it worked like a charm. Again, thank you :)
I can’t change the width of the message area. I can change the height easily enough but the width just doesn’t change. I am using the following code:
[textarea* about-store 200*6]
Thanks for the plugin though. It is exactly what I was looking for.
[…] Contact Form 7 1.7.6 […]
[…] Contact Form 7 – formulario de contacto simple y facil de usar, puedes ver u ejemplo en la página de Acerca De […]
Hi,
my contact form is not Valid XHTML “http://www.denis-online.de/kontakt/” its only on the page where the contact form is. How can i fix it?
Cheers
denis
Alan,
Its correct format is …
[textarea* about-store 200x6]Use
x, not*.Denis,
Thanks for the info. I confirmed it on my site, too. It seems a bug. I’ll fix it in next release.
Any plans to make it work on IE 8?
Right now the little icon simply shows up when clicking the submit button but nothing else ever happens. Same with IE7. Seeing as 80% of the world still uses IE it might be a good idea to support it. ;) I’ve gotten over 200 emails from people complaining that the form was not working. :(
war59312,
Contact Form 7 works on IE 7. I don’t know about IE 8. what is it :P
BTW, I checked your form page with Firebug and found two syntax errors. I guess that conflict between plugins is causing this issue.
This plugin is nice, and I want to use it… but, inserting a form with this plugin adds 21 validation errors to my blog!! :( (only in the contact page of course).
You can check my blog index, or single post, and you can see that is xhtml 1.0 valid, but the contact page with the form generated by your plugin is a chaos!! (if I removed the form, all goes to xhtml valid).
I have been looking in your code and I see some BIG mistakes, for instance, you define the same id twice (in line 581 and 587 of the file wp-contact-form-7.php), an ID must be UNIQUE in a xhtml document, so that is the first validation error.
You use a lot of
tags to make some space, but forget to close some of them, so more errors of validation…I recommend you to do a big cleanup of the xhtml code generated, because actually is pretty bad :(