According to the official explanation there are three reasons. The first one: "At the Centennial Exhibition in Philadelphia on Jersey Day, August 24, 1876. Alfred M. Heston states in his 1926 work, Jersey Waggon Jaunts, that "The Garden State" was used by Abraham Browning, of Camden. "In his address Mr. Browning compared New Jersey to an immense barrel, filled with good things to eat and open at both ends, with Pennsylvanians grabbing from one end and the New Yorkers from the other. He called New Jersey the Garden State, and the name has clung to it ever since."
For the other two go to the following link:
New Jersey