Before we dive into reasons that privacy may have developed in humans, let's speak for a moment about what "privacy" really means. When we talk about the concept in relation to, say, the U.S. National Security Agency reading our e-mails, we're concerned with information that may reveal something about us or our activities. But remember that privacy can also mean isolation; being alone or unobserved, for instance.
On the latter point, there certainly seems to be a biological basis for why humans wouldn't always want to be surrounded by one another. Think about animals who want to keep competitors out during breeding season. They're demanding privacy just like (most) humans do when it comes time to mate. We assume our need to not broadcast our sexual activities has to do with "privacy," when, in fact, it may have developed as a necessary practice to make sure there wasn't an unwelcome rival infringing on our own mating ritual.
But what about privacy when it isn't necessarily about isolation? Why do we value keeping some things close to the vest? Competitive advantage is one potential reason. Back in the day, perhaps this meant not sharing that we found a sweet supply of nonpoisonous berries. Withholding that information might give us a few more needed calories than our neighbor.
We can also view privacy as a way to achieve goals. By keeping some information to ourselves, we might be less of a target for others to try to usurp a position we've gained or are trying to gain. Think this sounds crazy? Consider that for many years, it wasn't unheard of for working mothers climbing a corporate ladder to avoid talking about their children in the office. They assumed -- rightly or wrongly -- that the perception of them as a parent would overshadow their goals as an employee.
So when you're wondering if the government is reading your steamy texts, be assured you're just reacting to the biological need to protect your territory and mate. Or something like that.