Spencer is located at . Spring Creek flows through the city. According to the United States Census Bureau, the city has a total area of, of which, is land and is water.
As of the census of 2010, there were 2,322 people, 1,005 households, and 578 families living in the city. The population density was. There were 1,180 housing units at an average density of. The racial makeup of the city was 97.5% White, 0.1% Native American, 0.3% Asian, 0.6% from other races, and 1.5% from two or more races. Hispanic or Latino of any race were 1.7% of the population. There were 1,005 households of which 28.3% had children under the age of 18 living with them, 38.5% were married couplesliving together, 13.6% had a female householder with no husband present, 5.4% had a male householder with no wife present, and 42.5% were non-families. 37.6% of all households were made up of individuals and 17.7% had someone living alone who was 65 years of age or older. The average household size was 2.25 and the average family size was 2.94. The median age in the city was 40.2 years. 23.2% of residents were under the age of 18; 8.5% were between the ages of 18 and 24; 23.5% were from 25 to 44; 26.3% were from 45 to 64; and 18.5% were 65 years of age or older. The gender makeup of the city was 46.7% male and 53.3% female.
2000 census
As of the census of 2000, there were 2,352 people, 1,005 households, and 614 families living in the city. The population density was 1,984.3 people per square mile. There were 1,154 housing units at an average density of 973.6 per square mile. The racial makeup of the city was 97.62% White, 0.13% African American, 0.21% Native American, 0.68% Asian, 0.04% from other races, and 1.32% from two or more races. Hispanic or Latino of any race were 0.77% of the population. There were 1,005 households out of which 27.6% had children under the age of 18 living with them, 44.2% were married couples living together, 12.9% had a female householder with no husband present, and 38.9% were non-families. 35.0% of all households were made up of individuals and 19.8% had someone living alone who was 65 years of age or older. The average household size was 2.25 and the average family size was 2.89. In the city, the population was spread out with 23.9% under the age of 18, 8.3% from 18 to 24, 23.6% from 25 to 44, 22.1% from 45 to 64, and 22.2% who were 65 years of age or older. The median age was 41 years. For every 100 females there were 86.1 males. For every 100 females age 18 and over, there were 80.6 males. The median income for a household in the city was $19,773, and the median income for a family was $28,500. Males had a median income of $28,000 versus $16,452 for females. The per capita income for the city was $12,976. About 24.9% of families and 31.0% of the population were below the poverty line, including 42.8% of those under age 18 and 21.4% of those age 65 or over.