Writing mostly surfaces from the subconcious, and dreams are our window to our subconcious. Some of the most wonderful ideas can strike you just as you begin to wake up, ideas not necessarily practical, but with undeniable potential to develop into a story.
From the cusp of sleep and awakening it is possible to pull out skeins that can become anything you want it to, a poem, a flash story, a short story, a novella…. the sky is the limit.
I always keep a pencil and notebook handy beside my bed, and on mornings I wake up from a memorable, yet already half-forgotten dream, I make a few notes. That is where I get most of my imagery from, even sometimes for some of my most everyday articles. I was checking the internet for people who write dream journals, and I found an interesting one that reminded me of so many things about my own dreams.
Turning dreams into reality can work out even in the most literal sense.
To write a story, look for one in your dreams.