You can either learn fear of failure, or it becomes engendered in you through neglectful parenting. I believe that fear of failure comes from a core feeling of not being good enough, which is turn stems from a child’s feeling of being unloved, and perhaps being overtly or covertly criticised.