In his later work, Freud proposed that the human psyche could be divided into three parts: Id, ego and super-ego. Freud discussed this model in the 1920 essay Beyond the Pleasure Principle, and fully elaborated upon it in The Ego and the Id (1923), in which he developed it as an alternative to his previous topographic schema (i.e., conscious, unconscious and preconscious).
The id is the completely unconscious, impulsive, childlike portion of the psyche that operates on the "pleasure principle" and is the source of basic impulses and drives; it seeks immediate pleasure and gratification.
Freud acknowledged that his use of the term Id (das Es, "the It") derives from the writings of Georg Groddeck. The super-ego is the moral component of the psyche, which takes into account no special circumstances in which the morally right thing may not be right for a given situation.
The rational ego attempts to exact a balance between the impractical hedonism of the id and the equally impractical moralism of the super-ego; it is the part of the psyche that is usually reflected most directly in a person's actions. When overburdened or threatened by its tasks, it may employ defense mechanism.