The formalin test is a valuable tool widely used in animal pain studies. We offer a new automated technique based on continuous recording of movements of animals injected in a hindpaw with formalin (5%). This method, based on image processing, allows the discrimination of specific pain-induced behaviors and general motor activity. The comparison of the pain scores evaluated by manual and automated methods showed the same biphasic response. This new process was validated by using compounds known to alter pain responses to formalin: morphine and a non-steroidal anti-inflammatory drug (ketoprofen). Morphine dose-dependently usually affects the two phases of formalin response with ED50 of 2.0 +/- 0.5 and 1.5 +/- 0.5 mg/kg s.c. for the first and the second phase, respectively. The injection of ketoprofen significantly decreased pain scores of the second phase but not those of the first phase. The specificity of the method was studied by determining the effect of diazepam. This sedative compound induced a decrease in pain scores as well as a decrease in motor activity parameters. These data show that this automated technique can be considered as a relevant, sensitive and specific tool which allows the easier use of the formalin test especially for the screening of analgesic drugs. (C) 1997 International Association for the Study of Pain. Published by Elsevier Science B.V.