The id, ego and superego are the three parts of the psychic apparatus defined in Sigmund Freud’s structural model of the psyche; they are functions of the mind.
The Id is the aspect of personality that is driven by internal and basic drives and needs. These are typically instinctual, such as hunger, thirst, and the drive for sex, or libido. The id acts in accordance with the pleasure principle, in that it avoids pain and seeks pleasure. Due to the instinctual quality of the id, it is impulsive and often unaware of the implications of actions. It is unconscious, selfish, childish and present from birth.
The Superego works in contradiction to the id and it comprises the organized part of the personality structure, mainly but not entirely unconscious, that includes the individual’s ego ideals, spiritual goals, and the psychic agency (commonly called “conscience”) that criticizes and prohibits one’s drives, fantasies, feelings, and actions. The Super-ego can be thought of as a type of conscience that punishes misbehavior with feelings of guilt, controlling our sense of right and wrong.
The ego acts according to the reality principle and holds psychic functions such as judgment, tolerance, reality testing, control, planning, defense, synthesis of information, intellectual functioning, and memory, which help us to make sense of our thoughts and the world around us. It also acts as a moderator between the id and superego. When a conflict arises between the two, the Ego employs defense mechanisms.