The Folly of Fools: The Logic of Deceit and Self-Deception in Human Life (2011, Basic Books, ISBN 0465027555) by Robert Trivers is a book that examines the evolutionary explanations for deceit and self-deception. Trivers focuses primarily on humans but he includes examples from many other organisms as well. Trivers' starting point is to illustrate that self-deception is something of an evolutionary puzzle. While the evolutionary benefits to deceiving other organisms are obvious at first glance it seems highly counter-intuitive to think that it could ever be in the evolutionary interest of an organism to deceive itself.
In the book Trivers discusses the evolutionary reasons for animals engaging in self-deception. He provides numerous examples of this both at the individual level and at the societal level, eventually discussing examples of self-deception in the history of the United States and Israel.
The essence of his analysis is that "the primary reason we fool ourselves is to fool others". Humans are exceptionally good at picking up various verbal and physical cues (e.g., speech intonation, eye movements,...) that indicate when another human is practicing deception. There are many situations such as playing "chicken" and seeing who will back down first, where it can actually benefit an organism to deceive itself, by so doing the organism can better deceive others.[ 1] [ 2]