The Oedipus complex is a psychoanalytic theory pioneered and made famous by Sigmund Freud. The theory, first put forth by Freud in 1897 although not fully defined until much later in his career, suggests that children have a subconscious and repressed desire to possess one of their parents and eliminate the other parent. The exact nature of the theory and the child's subconscious desire varies between sons and daughters.
The name and concept of the theory were derived from a Greek myth in which Oedipus Rex accidentally killed his father and married his mother. Freud borrowed the term and began applying it to his patients after conducting case studies which demonstrated the existence of an unconscious desire to own or possess a parent. Freud developed the theory throughout his career, ultimately coming to believe that this desire is universal and is healthy.
Freud's theory of the Oedipus complex initially applied only to boys. Under the theory, sons have a subconscious attraction to their mothers and thus see their fathers as a threat, and also come to believe that castration is the likely outcome of the rivalry, thus developing castration anxiety. Freud believed that this Oedipal desire primarily occurred in boys between the ages of three and five.
Freud eventually expanded the theory to include girls as well. Freud, however, believed that the theory manifested in girls as a strong homosexual attraction to their mother, before eventually becoming father-fixated when they became disappointed with their mothers as a result of their mothers' lack of a penis. Thus, Freud suggested that the development of the Oedipus complex in females was more complex than the development the Oedipus complex in males, and led to the development of penis envy.
In addition to believing that the Oedipus complex and the Oedipal desire are natural, Freud also believes that successful resolution of the complex is essential to well being. He postulated that failing to work through the Oedipus phase and resolve the desire could lead to sexual behavior considered deviant, such as sexual neurosis, pedophilia, and homosexuality.
Under Freud's theory, children work through their Oedipal phase by developing a deep affinity with the same-sex parent. In other words, children lose the desire to possess their opposite sex parent and instead begin to identify with the parent who is the same sex they are. Sexual desires are thus redirected elsewhere.