Gary is a city in Deuel County, South Dakota, United States. The population was 227 at the 2010 census. South Dakota Highway 101 serves as the main route of the community.
A post office called Gary was established in 1874. Gary was platted by the railroad in 1877. It was named for H. B. Gary, a postal official. An early variant name was State Line.
Gary is located at 44°47′35″N 96°27′27″W (44.793178, -96.457569).
According to the United States Census Bureau, the city has a total area of 0.69 square miles (1.79 km2), all land. The West Branch of the Lac qui Parle River flows through the city as a spring fed stream near its headwaters.
Gary has been assigned the ZIP code 57237 and the FIPS place code 23860.
As of the census of 2010, there were 227 people, 120 households, and 61 families residing in the city. The population density was 329.0 inhabitants per square mile (127.0/km2).