It depends on how badly you want the job, rejection sucks but as to how much it sucks that directly depends on how badly you wanted whatever it is that you got rejected from.Well it certainly does not need to be. If it is then I think an adjustment of mindset is needed in order to have a healthier outlook about that. Because unless you acted like a complete jerk in the interview, the rejection is not an indictment of you as a person.
As I said, it is possible that every applicant was equally qualified and the employer would have liked to hire them all. But if there is only one opening, they have to choose one. It could have literally been a flip of a coin at that point.
As applicants, we do not know what is going on in the background of the hiring process. That is not shared with us. But there is no reason to assume that they looked down on you if you know you were qualified and you know you acted in a dignified manner in the interview.
I think you ought to take a different view of this.
You mention job interviews. When you apply to a job part of the process might involve an interview with some big CEO, somebody way up in the chain of command. No matter how well prepared you go in, there is always the chance you might embarrass yourself at the interview no matter how small. The only way to 100% guarantee you won't embarrass yourself at the interview is to not go to the interview, but then of course you won't get the job.