> ## Documentation Index
> Fetch the complete documentation index at: https://kb.hosting.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Adding CAPTCHA protection to your web site

> Explore CAPTCHA protection: what it is, implementation in various languages, and its benefits for your website.

This article describes what CAPTCHA protection is, when you might use it, and some implementations for various programming languages that you can add to your own web site.

## What is a CAPTCHA?

A CAPTCHA (**C**ompletely **A**utomated **P**ublic **T**uring test to tell **C**omputers and **H**umans **A**part) is a test that tries to determine if a user is a human or a computer. The most common type of CAPTCHA is an image of obscured letters or numbers displayed in a box. A user must type the letter or number sequence correctly before he or she can access web site content or submit data. Because automated bots usually cannot read these images, they are prevented from misusing a web site's resources.

The following image is an example of a common type of CAPTCHA:\
![Example CAPTCHA image](https://static.hosting.com/kb/kb-captcha-example.png)

## When to use CAPTCHA protection

You should consider adding CAPTCHA protection to your web site if it has any of the following:

* Forms that process user-submitted data, including e-mail forms, comment forms, and registration forms.

* Surveys or polls.

* Pages that accept file uploads or downloads by users.

* Any other pages that accept user-submitted data.

## CAPTCHA implementations

There are several free and open source CAPTCHA implementations available, depending on the programming language that your web site uses.

### PHP

These are some of the numerous CAPTCHA implementations available for PHP:

* The Securimage script enables you to easily add PHP-based CAPTCHAs to a web site. For more information, please visit [http://www.phpcaptcha.org](http://www.phpcaptcha.org).

* The captchas.net service provides CAPTCHA implementations for several languages, including PHP. For more information, please visit [http://captchas.net/sample/php](http://captchas.net/sample/php).

* Google provides the reCAPTCHA service. For general information about reCAPTCHA, please visit [http://www.google.com/recaptcha](https://www.google.com/recaptcha). For specific information about implementing reCAPTCHA with PHP, please visit [https://developers.google.com/recaptcha/intro](https://developers.google.com/recaptcha/intro).

* If you are a programmer and would like to write your own CAPTCHA implementation, you can use the Text\_CAPTCHA PEAR package in PHP. For more information, please visit [http://pear.php.net/package/Text\_CAPTCHA](http://pear.php.net/package/Text_CAPTCHA).

### Python

The captchas.net service listed above for PHP also has a Python implementation. For more information, please visit [http://captchas.net/sample/python](http://captchas.net/sample/python).

## More information

For more information about CAPTCHAs, please visit [http://en.wikipedia.org/wiki/CAPTCHA](https://en.wikipedia.org/wiki/CAPTCHA).

## Related articles

* [Adding CAPTCHA protection to a WordPress site](/docs/adding-captcha-protection-to-a-wordpress-site)

* [Adding CAPTCHA protection to an Elgg site](/docs/adding-captcha-protection-to-an-elgg-site)
