Plan for plot twists while you're outlining your first draft. Find places in your story where you can surprise the reader by revealing something unexpected or having a course of action turn out differently than he will anticipate.
Allow your plot to twist while you're writing. Be creative while you're writing your first draft. Ask yourself continually what aspects of your story could be different than they seem to be. Could a character who appears evil actually be good, or vice versa? Think about what your reader will expect to happen; then do something different.
Follow every action in your story to its logical conclusion. Don't be afraid to deviate from your outline or change your planned ending--that's what first drafts are for.
Choose plot twists that do more than change the plot. The plot twists should be natural consequences of who your characters are, and they should change the way your characters see the world.
Go back through your story after it's finished and find the plot twists and changes that occurred while you were writing. Choose the ones you want to keep.
Foreshadow the plot twists by planting clues in earlier scenes that indicate what's really going to happen. Make these clues subtle: you want your reader to notice them but not realize their importance at the time.
Plant other clues in early scenes that will misdirect the reader. You want the reader to be surprised by the plot twist, so make sure there's enough evidence that something else could happen. Create events that will give the appearance of something different from the truth without actually lying to the reader.
Explain the misdirection clues during or after the plot twist, if necessary. For example, if your novel is a mystery and one character was seen leaving the building just before the body was found, you need to explain what that character was really doing when you reveal who the true murderer is.