The Pinkerton National Detective Agency was formed in 1850 by Scottish immigrant Allan Pinkerton as a private detective agency. The first office was located in Chicago, Illinois. The agency adopted the Pinkerton Code that same year, consisting of seven edicts to guide agents of the company.
Business for the Pinkerton Agency picked up in the latter 19th century as it worked with local law enforcement to apprehend criminals. Additionally, Allan Pinkerton worked with the federal government immediately prior to and during the American Civil War as the head of the Union Intelligence Service, even foiling an early assassination attempt on President Lincoln. Pinkerton later died in 1884, and control of the company passed on to his sons Robert and William.
The Pinkerton agency notably pursued several Western outlaw gangs led by legendary figures such as Jesse James and Butch Cassidy. It was also made infamous during actions in the Homestead Strike, in which Pinkerton detectives fought with striking steelworkers, leaving 16 dead and 23 wounded.
By 1906, the Pinkerton firm had grown to 20 offices across the country. The following year, Allan Pinkerton II inherited leadership of the company. Under his direction, the business flourished for decades, acquiring the Securitas AB private security force in 1999.