Tom and Huck's discovery of buried treasure changes the entire village: Everyone now seeks out old haunted houses and digs in vain for buried treasure. The Widow Douglas invests Huck's money at 6 percent, and Aunt Polly has Judge Thatcher do the same for Tom. This is wealth, a dollar a day for every weekday and half a dollar on Sunday at a time when "a dollar and a quarter a week would board, lodge, and school a boy el and clothe him and wash him, too, for that matter."
Judge Thatcher "has conceived a great opinion of Tom" for getting Becky out of the cave. Thus when Becky tells her father about Tom's taking the blame for Becky's misconduct and taking her punishment, the judge claims that "it was a noble, generous, a magnanimous lie."
Huck Finn finds wealth a burden. He has to dress properly, eat at a table with a knife and a fork, and sleep in a clean bed. More horrible, Huck has to quit smoking and swearing. In other words, he has to live a sterile, boring, and civilized life, and so he disappears. Three days later, Tom finds him in a hogshead behind a slaughterhouse, dressed in his old loose-fitting clothes and smoking. Huck tells Tom that he cannot stand civilization; he feels too crushed. Even the new tight-fitting clothes smother him; school is about to open, and he does not want to go to school.
Tom tries to convince Huck that all the things Huck objects to are the things that the other boys have to endure. Nothing convinces Huck until Tom tells him that he cannot join his band of robbers unless he is respectable. Huck, Tom continues, cannot have a place in the gang because people would say "Sawyer's Gang! Pretty low characters in it!" And they would be referring to Huck Finn. Huck then promises that he will return to the Widow's for a month and will follow most of her rules if Tom will get her to ease up a little bit on him. They look forward to getting the gang started, and plans are made for a swearing-in ceremony that will be performed with real blood and on top of a coffin.
Twain declares his novel finished and describes Tom's status at the same time: "So endeth this chronicle. It being strictly a history of a boy, it must stop here; the story could not go much further without becoming the history of a man." An so the novel ends.
At the end of the novel, Tom asks Huck to shed his ways and become a member of society, that is to become respectable. Society is Tom's way of life, and he does not want to escape from it except in his childhood games of pretend. Huck, however, foreshadows the Huck of Huck Finn, a fourteen-year-old person who has tried society and has rejected it. (Interestingly, Twain ends Adventures of Huckleberry Finn in much the same way: There, again, Huck wants to escape from the confining rules and hypocrisy of society in favor of a life of adventure and freedom.)
Tom, in contrast, is preparing again for his make-believe world. In this make-believe world, Huck Finn cannot become a member of Tom's band of robbers unless in the real world he becomes respectable. The irony escapes Tom, but is apparent to the adult reader--a fact that again shows this novel's appeal to both children and adults, alike.
The ending of Tom Sawyer served Twain as a jumping off point for his next novel, which he would not complete for another eight years: Adventures of Huckleberry Finn. It is as though he had discovered his favorite character in Huck, a person who lived apart from normal society and who, from the perspective of an outsider, would be able to criticize it.