Huck Finn, now rich from the treasure he and Tom Sawyer found, is being 'sivilized' by the Widow Douglas and chafing under it when his violent, drunken father turns up to seize his money. Locked away in a cabin and beaten, Huck stages his own murder, slips off down the Mississippi, and hides out on Jackson's Island, where he finds Jim, a man owned by Miss Watson who has run off because he is about to be sold away from his family.
The two become fugitives together and take to a raft heading downriver. Twain alternates the open river, where life is unhurried and the sky is 'all speckled with stars,' against the violent shore, where Huck stumbles into a wrecked steamboat full of robbers, a deadly family feud, lynch mobs, and small-town meanness. The raft is a refuge; the land is where people do harm to one another in the name of honor, law, and religion.
Their bond deepens through ordinary moments and a few sharp ones. After Huck plays a cruel trick, Jim's quiet rebuke about friendship shames him into apologizing to a man he has been taught to consider beneath him. Huck sees Jim mourning for his own children and admits he believes Jim cares for his family as much as any white man cares for his. These small recognitions steadily undercut everything Huck has absorbed about slavery.
Downriver the raft is overtaken by two con men, the 'duke' and the 'king,' who drag Huck and Jim through a run of swindles and finally sell Jim back into captivity for forty dollars. Alone, Huck faces the book's central crisis. His upbringing tells him the godly act is to write to Miss Watson and return her property. He writes the letter and feels cleansed, then remembers Jim's kindness, tears the letter up, and resolves to steal Jim out of slavery even though he is sure it means he will 'go to hell.'
The last stretch turns farcical when Tom Sawyer reappears and insists on freeing Jim by an absurdly elaborate scheme, even though Tom secretly knows Miss Watson has already freed Jim in her will. The plan goes wrong, Tom is shot, Jim gives up his own escape to help nurse him, and the truth comes out. Jim is free, Huck's father is revealed to be long dead, and Huck, unwilling to be civilized all over again, decides to 'light out for the Territory ahead of the rest.'