They can be formatted in several different ways. When indicating omission, you can have ellipses with no spaces (word...word); with spaces after and before the words but not within the ellipses (word ... word); or with spaces between each character (word . . . word). When indicating hesitation, you can have ellipses with a space after (word... word); or with spaces between each character (word . . . word). Personally, I strongly recommend ellipses with spaces (word . . . word).
In stories, ellipses are most often used to indicate hesitation in dialog. Some examples:
"I think . . . that we should take the gorilla with us," Ben said.
". . . How are we going to fit it in the car?" Erin asked.
"Well . . . we could maybe, um . . . well, no . . ."
"No . . . ?"
Ben shook his head. "No . . . I guess we can't take it with us."
Note that when ellipses are used to indicate hesitation at the beginning of the sentence (in the second line), the sentence still begins with a capital letter. When the ellipses indicate a question that has trailed off, they are followed by a question mark, as shown in the fourth line.
Ellipses aren't often used to indicate omission in stories; that's a use that tends to spring up more in academic writing, when quoting another author. However, on occasion, you might use ellipses in your story to indicate that illegible or indistinct words have been omitted:
Ben squinted at the old note. The pencil had smeared or faded in places, leaving many of the words illegible. All he could make out was, "Diana . . . should have met . . . before I left. I . . . have seen you . . . to face."
Erin pressed her ear to the door. Her manager and the strange woman were having a conversation, but she could only make out bits and pieces of the conversation.
"I don't think . . . be here," her manager said.
"It doesn't matter . . . think. She's . . . with me," the woman replied.
Things to look out for
Be consistent: You can format your ellipses with or without spaces; just make sure that you use the same formatting throughout your entire manuscript.
Avoid using ellipses outside of your dialog: The primary purpose of ellipses in dialog is to mimic the natural hesitations and pauses of human speech. You can also use them in your character's thoughts to similar effect. However, unless you're writing in first person, you should avoid using ellipses outside of dialog, as it will make your prose seem overly informal and disjointed.
Avoid over-using ellipses: Even in dialog, a large cluster of ellipses will distract your reader's eyes and interrupt the flow of the text. Look at each ellipses in your manuscript and ask yourself, what does this ellipses mean? Is it indicating a meaningful pause for thought or showing a character's discomfort? Is this pause really necessary?
Don't break up your ellipsis points: Your word processor will split lines of text at any available space. This means that you can sometimes have one or two ellipsis points at the end of one line and the remaining one or two points at the beginning of the next line. It's not really a mistake, but it sure doesn't look good. If you spot this happening, try putting some non-breaking spaces between the ellipsis points (usually in the menu under Insert > Insert Special Characters > Non-breaking Space). These will give you the proper spaces between the points without letting the processor split them up.