Legend has it that the Tar Heel nickname applied to the state and inhabitants of North Carolina--as well as the University of North Carolinas athletic teams--dates back to the Civil War. Supposedly, during a battle in Virginia the North Carolinian troops held their ground while supporting troops retreated. After the battle, supporting troops asked the victorious North Carolinians: "Any more tar down in the Old North State, boys?" and they replied: "No, not a bit; old Jeff's bought it all up." The supporting troops continued: "Is that so? What is he going to do with it?" The North Carolinian troops' response: "He is going to put it on you'ns heels to make you stick better in the next fight." 
In fact, the term Tar Heel is a pejorativemuch like the term Georgia crackerthat dates back to colonial times. North Carolina was the poorest of the 13 original colonies, and the states primary exports were naval storespitch and tar. Tar Heel was thus an insult levied at the states residents who were so poor and ignorant that they walked around barefoot with tar on their heels.