Hamburg is a village in Erie County, New York, United States. The population was 9,696 at the 2020 census.[2]