Shelly was platted in 1896, and named for John Shely, an early settler. The spelling of "Shelly" was adopted to distinguish the city from the already existing Shely Township. A post office has been in operation at Shelly since 1896.
As of the census of 2010, there were 191 people, 90 households, and 46 families living in the city. The population density was. There were 117 housing units at an average density of. The racial makeup of the city was 94.2% White, 3.1% Native American, 0.5% Asian, and 2.1% from two or more races. Hispanic or Latino of any race were 8.9% of the population. There were 90 households of which 20.0% had children under the age of 18 living with them, 43.3% were married couplesliving together, 5.6% had a female householder with no husband present, 2.2% had a male householder with no wife present, and 48.9% were non-families. 44.4% of all households were made up of individuals and 27.8% had someone living alone who was 65 years of age or older. The average household size was 2.12 and the average family size was 3.04. The median age in the city was 45.9 years. 23.6% of residents were under the age of 18; 3% were between the ages of 18 and 24; 20.9% were from 25 to 44; 27.8% were from 45 to 64; and 24.6% were 65 years of age or older. The gender makeup of the city was 46.1% male and 53.9% female.
2000 census
As of the census of 2000, there were 266 people, 111 households, and 66 families living in the city. The population density was 1,271.2 people per square mile. There were 122 housing units at an average density of 583.0 per square mile. The racial makeup of the city was 86.47% White, 7.14% Native American, 6.02% from other races, and 0.38% from two or more races. Hispanic or Latino of any race were 13.16% of the population. There were 111 households out of which 24.3% had children under the age of 18 living with them, 46.8% were married couples living together, 10.8% had a female householder with no husband present, and 40.5% were non-families. 39.6% of all households were made up of individuals and 18.0% had someone living alone who was 65 years of age or older. The average household size was 2.40 and the average family size was 3.26. In the city, the population was spread out with 28.2% under the age of 18, 5.6% from 18 to 24, 30.5% from 25 to 44, 16.2% from 45 to 64, and 19.5% who were 65 years of age or older. The median age was 37 years. For every 100 females, there were 90.0 males. For every 100 females age 18 and over, there were 89.1 males. The median income for a household in the city was $28,750, and the median income for a family was $34,063. Males had a median income of $29,432 versus $20,625 for females. The per capita income for the city was $15,338. About 10.8% of families and 14.8% of the population were below the poverty line, including 21.1% of those under the age of eighteen and 11.4% of those sixty five or over.