Gainesville is a village in Wyoming County, New York, United States. The population was 304 at the 2000 census. The village is named after General Edmund P. Gaines. The Village of Gainesville lies within the boundaries of the Town of Gainesville. The village is on NYS Route 19, south of NYS Route 78.