According to the United States Census Bureau, the city has a total area of 3.3 square miles (8.5 km2), of which 1.0 square mile (2.6 km2) is land and 2.2 square miles (5.7 km2) (68.50%) is water. The city is located on a barrier island between the Gulf of Mexico to the southwest and Boca Ciega Bay to the northeast. One bridge, the Tom Stuart Causeway, connects Madeira Beach to the mainland, in the unincorporated community of Bay Pines. To the northwest of Madeira Beach is the town of Redington Beach, and to the southeast, across the inlet of John’s Pass, is the city of Treasure Island. As of the census of 2000, there were 4,511 people, 2,528 households, and 1,122 families residing in the city. The population density was 4,392.0 per square mile (1,691.0/km²). There were 3,976 housing units at an average density of 3,871.1 per square mile (1,490.4/km²). The racial makeup of the city was 97.05% White, 0.27% African American, 0.31% Native American, 0.58% Asian, 0.04% Pacific Islander, 0.67% from other races, and 1.09% from two or more races. Hispanic or Latino of any race were 2.37% of the population.
There were 2,528 households out of which 9.1% had children under the age of 18 living with them, 35.6% were married couples living together, 5.6% had a female householder with no husband present, and 55.6% were non-families. 42.4% of all households were made up of individuals and 12.2% had someone living alone who was 65 years of age or older. The average household size was 1.78 and the average family size was 2.36. In the city, the population was spread out with 8.2% under the age of 18, 4.8% from 18 to 24, 29.3% from 25 to 44, 35.7% from 45 to 64, and 22.0% who were 65 years of age or older. The median age was 48 years. For every 100 females, there were 111.3 males. For every 100 females age 18 and over, there were 110.2 males. The median income for a household in the city was $36,671, and the median income for a family was $50,833. Males had a median income of $32,353 versus $27,455 for females. The per capita income for the city was $30,097. About 4.1% of families and 9.8% of the population were below the poverty line, including 4.1% of those under age 18 and 12.2% of those age 65 or over.