As a child, Jules Verne was fascinated by travel, watching boats moving along the Loire River in France and writing adventure stories during his classes. Verne's family moved between Summer and Winter houses, which gave him a comfortable association with travel.
There is a mythic story about Verne, unconfirmed to this day, that as a child he stowed away on a steamship traveling to the West Indies, and was only caught when his father met him at the next port. Although this story is only rumor, it ties well into the idea that he was obsessed with travel, and was likely invented by a biographer based on the (also unconfirmed) story that Verne rented a boat at age 11 to meet a steamship.
During his school years, Verne spent much time traveling around France, both for his education and for his own interest. Since his family were of the wealthy middle-class, Verne's upbringing was one of routine and respectability. His personal rebellions, which included his focus on writing instead of law (the family trade) were difficult to achieve until his later life, and so he expressed his wish to escape the somewhat cloistered lifestyle in his writing. His more fanciful stories were a direct reaction to his staid life, and once he became independent, he focused on realistic tales of travel and adventure.