Something I don't think everyone considers when they don't get a job is that probably somebody else did get the job.
Maybe you are very skilled but only have 2 years experience and someone else that applied is just as skilled and has 5+ years experience. Maybe they interviewed that guy first and liked him and didn't feel the need to interview anyone else.
Maybe you are very skilled AND have 5+ years experience, but the hiring manager/HR had a stack of 10 (20? 100?) resume's of equally qualified applicants and you randomly ended up on the bottom of that stack (You have a 50% change of ending up in the bottom half) And they gave interviews to the first 5 (or 10 or 50) and ended up really liking one of those guys.
Maybe you are very skilled but only have 2 years experience and someone else that applied is just as skilled and has 5+ years experience. Maybe they interviewed that guy first and liked him and didn't feel the need to interview anyone else.
Maybe you are very skilled AND have 5+ years experience, but the hiring manager/HR had a stack of 10 (20? 100?) resume's of equally qualified applicants and you randomly ended up on the bottom of that stack (You have a 50% change of ending up in the bottom half) And they gave interviews to the first 5 (or 10 or 50) and ended up really liking one of those guys.