What is cgi?

Common Gateway Interface. A set of rules that describe how a Web Server communicates with another piece of software on the same machine, and how the other piece of software (the "CGI program") talks to the web server. Any piece of software can be a CGI program if it handles input and output according to the CGI standard. Usually a CGI program is a small program that takes data from a web server and does something with it, like putting the content of a form into an e-mail message, or turning the data into a database query. You can often see that a CGI program is being used by seeing "cgi-bin" in a URL, but not always.

Because CGI requests generally requires a fresh thread of the script to be executed for every request, it can load down the server. In these cases a more efficient script language such as PHP or ASP is recommended.