Caps are a metallic mesh partially fused to the scalps of humans. Their purpose is to mind-control the humans they are attached to, making them docile and obedient to the Masters. In the novels the caps are described as a spider web-like wiring that allows hair to grow through and conceal. The television show portrayed them as triangular circuitry as shown in the image here.
Soon after discovering Earth, the Masters started studying the human race and learned about their psychology and brain structure. Based on this knowledge, they were able to hypnotize many of them through The Trippy Show. They gave the hypnotized people temporary helmet-like Caps to secure control over them. These Caps were removable, although such an act left the human depressed and disoriented.
After the Tripod Invasion was successfully completed, the Masters started using permanent Caps, which they attached to all humans in a Capping Ceremony performed on 14-year-old children. After a while, almost all humans wore Caps.
The human resistance was able to attach false caps so they could move freely among the capped without suspicion. Agents with false caps posed as vagrants to scout the countryside for new recruits, or as spies to infiltrate the cities of the Masters. Close inspection of the false caps would reveal they were not properly fused to the skull.
There are two types of Caps. The prototype Caps were helmet-like that controlled a human's emotions once placed on his or her head. The Cap was removable, but doing so caused depression.
The newer version was smaller and more intricate and attached to a human's scalp. Once placed, these Caps could not be removed without killing the human. The Caps made the humans obedient to the Tripods and suppressed their creative sides. A Capped person would not ask questions or doubt the status quo. Although Will noted that those capped (unlike the older version) were still able to form close bonds and care for others. Many were genuinely kind and caring people providing such behaviour did not conflict with the tripods orders. This is presumably because once rule was established the Tripods were not present for much of everyday life save special occasions like capping day. Will and Fritz discovered in The Pool of Fire that shutting down the Pool of Fire left the Caps inactive and freed the humans of their mind-control. This implies that the Caps received some kind of signals from the Tripod Cities and were connected to them.