1. Even great candidates get rejected, so don’t take it personally. Especially in this job market, I'm turning down extremely qualified candidates constantly, simply because there are so many of them applying and I can only hire one of them for the job. Many times, I would happily hire plenty of the candidates who I have to reject.
2. Sometimes the person who rejects you for a job could be wrong. Hiring managers aren't infallible, and hiring isn't an exact science. We do the best we can with the limited information we have, so you shouldn’t take it as a measure of your worth.
3. Consider that the person may be right. Maybe your background wouldn't match with the job, and you'd be likely to struggle in it. Or, maybe your working style would clash with the company culture or the manager. Often, one personality type will simply fit better into a role than another would, and that's the kind of thing that's very difficult (if not impossible) for a candidate to know, looking in from the outside. Remember, it's not just a question of whether you have the skills to do the job, it's also a question of fit for this particular position, with this particular boss, in this particular culture, and in this particular company.
4. Rejection letters are rarely forthcoming about why you weren't hired. Don't try to read between the lines and figure out what they might be hinting at. They're not hinting at anything; they're just trying to deliver the news in the easiest way possible, and they're generally deliberately vague (because otherwise some people—not you, of course—will try to debate the decision).
5. Maybe you dodged a bullet. After all, you don't want a job in which you won’t excel, or a culture that would make you miserable, and maybe the hiring manager did you a favor in the long run.
Alison Green is the author of Managing to Change the World: The Nonprofit Leader's Guide to Getting Results. She is chief of staff for the Marijuana Policy Project, a nonprofit lobbying organization, where she oversees day-to-day management of the staff as well as hiring, firing, and staff development. Her writings have been published in the Washington Post, the New York Times, Maxim, and dozens of other newspapers. She blogs at Ask a Manager.