There is a great answer on Quora which includes this aspect (but also many others): https://www.quora.com/What-is-the-evolutionary-reason-for-mi...

Pasted below.

____

There are likely multiple evolutionary factors behind the tendency to create mischief.

Several concepts are interconnected with the idea of mischief:

- Playing fair vs. ignoring the rules (following/breaking social norms)

- Playing for fun vs. purposeful goal directed activity

- Pleasure derived from antisocial behaviors

- Pleasure derived from eliciting reactions in others

- Strategic reasons to create disruption

- The role of anonymity

Most of these have been studied separately, and not all of them may be required for an activity to be considered "mischief." Each one has its own set of evolutionary stories.

Breaking the rules: There are evolutionary advantages to the species as a whole (e.g. stable organized societies) for having everyone predisposed to following the social norms. Similarly, there are advantages to breaking the social norms: personal advantage in a world where others are unwilling to cheat, collective advantage to having a society that isn't 100% conformist (if the norms are bad, that will only be discovered if some people start breaking them and succeed).

Playing for fun (not goal-directed): Studies on play behavior in animals suggest that play during development serves several functions. It develops practice with give-and-take social interaction for more harmonious social order later, and physical play develops coordination that can help in adult behavior later (puppies playing and becoming better at fighting as dogs).

Pleasure derived from antisocial behaviors: This may fall a little bit outside of mischief, however the desire for revenge has been studied, as has duper's delight (pleasure from fooling others), or pleasure from cheating. In general, any behavior that could have an evolutionary advantage for some individuals is likely to have pleasure associated with it somehow, since that ensures that the behavior will be expressed. In any competition, using a strategy that would not occur to the opponent is to the individual's advantage because the opponent won't be planning to counter it. So whatever rules the opponent assumes you are playing by represent opportunities for advantage by ignoring them. There is the risk of winning the battle but losing the war (getting caught and punished), however this is a risk/reward trade-off.

Pleasure derived from eliciting reactions in others: There are rewards on multiple levels (neurological, social, existential) from getting others to respond:

- Neurological: Experiencing perceptual feedback to an action is inherently rewarding, which may relate to why kids enjoy hitting things and knocking things over. It is part of experimenting with and discovering the causal mechanisms of the environment.

- Social: A displaced or repurposed desire for social interaction, for example when preteens chase and hit girls or boys they are attracted to, or when adults "play the victim" to elicit sympathy.

- Existential: Feeling that one has an impact on the world, that one exists, that one matters. This might relate to enhancing the feeling of personal agency: the sense of power and causal control over the environment.

- Curiosity and personal amusement: Finding out what will happen, and watching the predictable reactions of others play out can be amusing (credit Naman Kumar).

There are also strategic reasons to create disruption in the specific social setting of a dialog (e.g. "trolling"):

- The disrupter wins social points for being dominant, tougher, funnier, and less naive than other participants.

- The bad boy (or b* girl) is admired by peers for being immune to the judgments and approval of others. From an evolutionary perspective, being revered by peers makes one attractive to potential mates in a social species (credit Ernie Bornheimer).

- Humor can be a way of moving the discussion away from an uncomfortable topic (credit Marcus Geduld).

- Sarcasm, ridicule, and shaming can be a strategy for shifting the power in a dialog, silencing opposing viewpoints, and changing the official view in the disruptor's favor (as with political debates).

Lastly, there is also the role of anonymity in mischief. Acting anonymously can be a way of playing out a fantasy without consequences to one's reputation in society. It certainly resolves one of the inner conflicts to antisocial behavior, the risk to one's reputation, by eliminating that risk altogether. Anonymity also facilitates pleasure derived from superiority, power, or knowledge. If you know something that no one else knows -- who is behind the mischief -- then you may be getting pleasure from what would normally be a positive evolutionary behavior: acquiring more knowledge than the next person, understanding causal mechanisms in the world, accumulating power.

Research on the neural basis of breaking the rules:

Moll J, et al (2005) The neural basis of moral cognition. Nature Reviews Neuroscience.

Spitzer M et al (2007). The Neural Signature of Social Norm Compliance. Neuron.

Sanfey AG et al (2003). The Neural Basis of Economic Decision-Making in the Ultimatum Game. Science.

de Quervain DJF et al (2004). The Neural Basis of Altruistic Punishment. Science.