I had same issue. One reason I never really went into depression was my lovely wife and my new born. I was close many times. What made it worse were few interviews where I scaled through about 5 rounds. They even contacted my reference and all that, just to hear they went with a more experienced guy. Why make me go through all those steps.
What I did eventually is join a really fast growing startup in a completely non-technical role. Build useful web app for the whole team within my role. Got noticed.Starts getting better from there. Location is also really important.Where I am based competition is fierce and inmigration laws makes it easy to just hire experienced guy from abroad.
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.