Written dialogue should mimic real life speech slightly to help the reader get the sense that the characters are real people. The subtle nuances of day-to-day human speech should be analyzed to ensure it is as realistic as possible. In spite of this, it is not necessary to go overboard with filler words and hesitation as this will bore the reader quickly.
It is not necessary to write a transcript of actual daily speech. It is merely enough to give the impression of speech. When writing dialogue, it is important to keep in mind that fictional characters, just like real people, will naturally possess different speech habits, accents and dialects. Ideally, each character's voice should be distinct enough to stand alone even without a dialogue tag, such as "he said," preceding it.
The cardinal rule of writing is always "show, don't tell." This means that a writer should take any possible opportunity to display a character's personality, motivation or inner feelings without explicitly telling the reader in the text. Dialogue helps this process along greatly. Instead of explaining in long, rambling detail what a character is thinking, a short piece of dialogue can vividly express a character's feelings without saying much at all.