Tom Sawyer got slammed by consecutive bad experiences with Becky Thatcher breaking up with him and alienating him, his Aunt giving up on him and then witnessing a murder that they were to scared to tell anyone about pushed him past the breaking point. When he ran into an almost suicidal Joe Harper feeling equally bad or worse, he recruited him to be on his pirating team. They made a very quick, secret pit stop back at their town and got Huck Finn to join as well. Their rag-tag group of depressed pirates set off for Jackson's Island on a raft.
“There was a small log raft there which they meant to capture. Each would bring hooks and lines, and such provision as he could steal in the most dark and mysterious way—as became outlaws.”
While this was a very rash decision made in their weakest and darkest moments, there is still hope for them to come back to live an honest and lawful life. Tom Sawyer and Joe Harper have too much good in each of their hearts to stay in a life of crime.