The setting took place somewhere between 1830s-1840s along side the Mississippi River, Illinois, and Arkansas where slavery was legal. This was twenty years before the civil war and everyone was an angry drunk.
The book was published on December 10th, 1884 and since then was on and off the banned books list. Huck Finn was ranked the 5th most challenged and banned book in its decade, and even till this day is ranked the 14th.
It took Mark Twain 8 years to write Huck Finn, which is filled with many challenging things during his time. Huck Finn was a very controversial book in that the main character went out of line, would do things for the good and even went as far as to reject slavery.