(Click the character infographic to download.)
Horatio is Hamlet's closest friend, and he's the only one who really seems to deserve the title. Unlike Rosencrantz and Guildenstern (also Hamlet's old chums), Horatio's loyalty and common sense are rock-steady throughout the play.
In fact, one of the first things we learn about Horatio is his good sense. When we first see Horatio, he's been called to the castle by the guards because he's a "scholar" (he goes to school in Wittenberg with Hamlet). That means he should be able to judge whether or not the apparition that's been appearing on the battlements is actually a ghost. According to Marcellus, Horatio says that the ghost is "but [the guards'] fantasy, / And will not let belief take hold of him" (1.1.28-29).
He's convinced of the spirit's legitimacy soon enough, but his initial skepticism introduces the first note of doubt in the play, one that will haunt his friend Hamlet for several acts.
Horatio digs Hamlet so much that he offers to commit suicide when his beloved Hamlet is dying (5.2.373-375). But Hamlet won't have it. He insists that Horatio live to tell the tragic story—which fits, since critics often note that Horatio's name recalls the Latin term "orator," or "speaker." And that's just what Horatio does. He promises to put the dead bodies up on a "stage" while he tells Prince Fortinbras and the rest of the world what went down in Elsinore:
And let me speak to the yet unknowing world
How these things came about. So shall you hear
Of carnal, bloody, and unnatural acts,
Of accidental judgments, casual slaughters,
Of deaths put on by cunning and forced cause,
And, in this upshot, purposes mistook
Fall'n on the inventors' heads. All this can I
Truly deliver. (5.2.421-428)
Hm. This is sort of what Shakespeare the playwright does, right? It's almost as though Horatio becomes a kind of playwright, using bodies to tell a story.