Wish fulfillment
This is the goal of every dream, according to Freudian dream theory. A dream is a manifestation of a wish being satisfied. It may be a simple wish, easily recognized, such as in the so-called "dreams of convenience": the body needs to urinate in the night, and so the sleeper dreams of relieving himself. But most dreams represent disguised wishes--unconscious desires that the conscious mind cannot accept, and so it is twisted into the bizarre narrative of a dream. Freud's method of dream interpretation consists of revealing the fulfilled wish at the source of every dream.
Source:
Freud, The Interpretation of Dreams

