Face detection is a computer technology that determines the locations and sizes of human faces in arbitrary (digital) images. It detects facial features and ignores anything else, such as buildings, trees and bodies. The softwares like picasa let you to search any image with a face of the person. Various social networking sites also added similar kind of functionality into their websites to make rich photo albums.
In this post, I’ll explain various plug-ins and libraries for face detection.

What is Face Detection?

Face detection is a technique where given image is searched for human faces. Face detection can be used to automatically detect and focus on face in profile pictures on social networking sites.

jQuery Face detection

A jQuery plug-in which detects faces in pictures and return their coordinates. The plugin uses algorithm designed by Liu Liu along with HTML5 canvas to get image data. That means the plugin will be only useful where client side browser support HTML5.

Demo Here
Code can be obtained from git hub

PHP FaceDetect Extension

Provides implementation of OpenCV in PHP. It provides two main functions face_count() and face_detect(). The first one returns count of faces found in a given image and second on returns array of their coordinates along with count.

Installation instructions and demo is available on XARG’s page.

Face Detection API

An API implemented by a Romanian developer for face detection. Simply send your API credentials along with URL of an image. The XML tree of faces along with 4 box coordinates will be returned. What makes this API useful is it takes image URL as an input and not image data. This means you can run this API on image hosted on public servers also.


Similar to PHP facedetect extension, a ruby binding to OpenCV is available at Rubyforge which can be used for face detection.


OpenCV handler for .NET framework which enables call to OpenCV functions from Csharp. It consists of a DLL (written in Managed C++) that wraps the OpenCV library in .NET classes, so that they will be available from any managed language (C#, VB.NET or Managed C++).