You have a plan, and that plan gives you control that you can do it. It is not just setting goals, but achievable goals. So you don’t say "I want to lose weight’, rather you say “I want to lose x pounds”. If you want to be a doctor, what is needed to achieve that goal? Overall the goal seems insurmountable, but if you break it into achievable chunks then you gain confidence that you ‘can’ do it. And from that comes success.
So in my opinion it stems from small steps that build your confidence. I am very successful in my chosen field. But I certainly recall as a freshman looking ahead at what it would take to become an Architect it was daunting. Yet bit by bit I achieved that goal, with each step gaining confidence.
I also think confidence is a measure of yourself against yourself and not an outside entity. I never measure my success as an Architect or a Father against others. It is how I feel about the work I do. There are people certainly more financially successful in my field then me, but I doubt many have the confidence I do about what I do. My clients trust me, I exude confidence that I know what I am doing (whether I do know is certainly open to interpretation!) but when my clients deal with me they don’t have any sense of that.
So I suppose it is, I feel confident so I am confident. At least that is how it is for me, but clearly others will have different opinions.