According to attachment theory (developed by Mary Ainsworth and John Bowlby), every child is born with an innate attachment system. The biological function of this system is to enhance the chances of survival through proximity seeking, particularly in times of distress and/or need. Although (almost) all children become attached to one or several caregiver(s), the quality of attachment can differ considerably between individuals. Such inter-individual differences emerge because there is a psychological correlate of attachment behavior, namely a felt sense of security.
If proximity seeking attempts are successful, a child learns that attachment figures are available in times of need, a pattern that supports the development of a secure attachment orientation. If proximity seeking attempts under stress do not succeed, however, the child will develop an insecure attachment orientation. The latter can either be avoidant in case of consistently unavailable / unresponsive attachment figures (also referred to as de-activating secondary attachment strategy), or anxious in case of unpredictable / unreliable attachment figures (hyper-activating secondary attachment strategy). In case of more severe neglect or abuse, a fourth attachment orientation called disorganized has furthermore been proposed.
Attachment theory postulates that such attachment patterns in early infancy and childhood become more and more cognitively encoded during later development (by means of so-called internal working models, or IWMs), remain rather stable across the life span, and influence many social emotional behaviors in childhood, adolescence, and adulthood (see also here). The plot thickens that attachment can even be transmitted from one generation to the next, and that it not only influences directly attachment-related processes, but (almost) all social interactions between people.
Recently, however, some of the core assumptions of attachment theory regarding its emergence during development, stability, mechanism of intergenerational transmission, and cross-cultural validity have been challenged (e.g. see here). In my opinion, it will therefore be important to provide more empirical data using social neuroscience methods in the future, ideally applying longitudinal research designs within large(r) participant samples. Please refer to my recent blog post on “21st Century Attachment Theory and Research: Embracing a Social Neuroscience Approach” for further reading.