Of the 30,708 total firearms-related deaths, only 11,798 -- slightly more than a third -- were homicides (some of which are justifiable).
Suicides account for well over half of the gun deaths -- 17,424, or 57%. An incredibly low 866 were accidents, and 620 were listed as "undetermined" or "other" -- which probably includes a lot more self-defense shootings.
Only seven tenths of one percent of criminals obtain weapons illegally at gun shows (See the U.S. Bureau of Justice Statistics Firearm Use by Offenders
Here are some other sources of statistics. If you know of any other good ones, please let me know