Town in Worcester County, Maryland

Ocean City, Maryland

6,840 residents · 1 ZIP Code

Population
6,840 ▼ 0.1% since 2020 (2025 est.)
Rank in state
174th largest of 383 places
Land area
4.4 sq mi · 1,546 people/sq mi
Time zone
Eastern Time
ZIP Codes
21842
Area code
410, 443, and 667
75.15°W75.10°W75.05°W75.00°W38.35°N38.40°N38.45°N218422 miN
Ocean City city limits (outlined) over the ZIP Codes that serve it.

What county is Ocean City in?

Ocean City is in Worcester County, Maryland.

What stands out in Ocean City

  • The share of residents born abroad is 10.1%, 2.1× the Worcester County (4.7%).
  • The average household size is 1.77 people, 19% lower than Worcester County (2.19 people).
  • The average commute is 20 minutes, 16% lower than Worcester County (23 minutes).
  • The share of adults with a bachelor's degree is 41.7%, 18% higher than Worcester County (35.3%).

ZIP Codes in Ocean City

ZIP CodeCityPopulationMedian incomeHome valueMedian ageShare in city
21842Ocean City11,226$79,876$447,70053.449% of ZIP

PO Box and unique ZIP Codes

People in Ocean City

Median age55.6
Under 189.4%
65 and older31.2%
Born abroad10.1%
Moved here in the last year13.9%

Age and sex

MaleAgeFemale
3.1%80+3.8%
6.3%70–797.3%
10.1%60–6910.4%
7.0%50–599.3%
6.0%40–493.2%
3.4%30–394.9%
7.1%20–297.5%
2.7%10–191.6%
3.0%0–93.3%
Share of all residents in each age group

Race and ethnicity

  • White84%
  • Hispanic or Latino9.5%
  • Other1.8%
  • Asian1.7%
  • Black1.6%
  • Two or more races0.9%
  • Pacific Islander0.4%
  • American Indian / Alaska Native0.1%

Hispanic or Latino residents can be of any race; the other groups count non-Hispanic residents only.

Households

3,828 households, 1.77 people per household on average, 50.1% family households, and 42.1% people living alone.

Income in Ocean City

Median household income$77,750±$4,829
Per-capita income$72,487
Poverty rate10.9%
Income inequality (Gini)0.540 = equal, 1 = unequal
12%Under $25k
17%$25k–50k
17%$50k–75k
17%$75k–100k
15%$100k–150k
8%$150k–200k
13%$200k+
Households by annual income

Housing in Ocean City

Median home value$429,000
Median gross rent$1,353/mo
Housing units29,811
Median year built1982
Vacant87.2%

Owners and renters

  • Owner-occupied 74.2%
  • Renter-occupied 25.8%

Types of homes

  • Single-family homes 22.3%
  • 2–9 unit buildings 14.8%
  • 10+ unit buildings 59.9%
  • Mobile homes, RVs 2.9%

Work, commute and education

Mean commute20 minone way
Unemployment rate5.7%
Labor force participation62%age 16+
Broadband at home95.1%households

How workers get to work

  • Drove alone66.3%
  • Carpooled4.1%
  • Public transit1.1%
  • Walked3.9%
  • Bicycle4.8%
  • Worked from home17.4%

Education, adults 25+

  • High school or higher95%
  • Bachelor's or higher41.7%
  • Graduate or professional degree16.4%

How Ocean City compares

Ocean CityWorcester CountyMarylandUnited States
Median household income$77,750$81,745$103,678$80,734
Per-capita income$72,487$53,274$52,979$44,673
Median home value$429,000$374,700$419,900$332,700
Median gross rent$1,353/mo$1,159/mo$1,705/mo$1,413/mo
Homeownership rate74.2%78%67.6%65.2%
Median age55.650.739.438.9
Bachelor's degree or higher41.7%35.3%43.4%35.7%
Poverty rate10.9%9.9%9.4%12.5%
Unemployment rate5.7%6.7%4.9%5.2%
Mean commute20 min23 min31 min26 min
Worked from home17.4%12.3%19.3%15.1%
Broadband at home95.1%91.2%92.4%91%
Foreign-born residents10.1%4.7%16.6%14.1%

Places near Ocean City

Area codes in Ocean City

Ocean City phone numbers use area codes 410, 443, and 667. See every phone prefix, carrier and the local time on Ocean City area codes at AreaCodeExplorer.

Ocean City, MD: questions and answers

What county is Ocean City, MD in?
Ocean City is in Worcester County, Maryland.
What ZIP Codes are in Ocean City?
Ocean City is served by 1 residential ZIP Code: 21842. PO Box ZIP Codes: 21843.
What is the population of Ocean City?
The Census Bureau estimates 6,840 residents in Ocean City in 2025.
What time zone is Ocean City in?
Ocean City is in the Eastern Time zone (America/New_York).
What is the area code for Ocean City?
Ocean City uses area codes 410, 443, and 667.

Sources: U.S. Census Bureau, American Community Survey 2020–2024 5-year estimates; 2025 Population Estimates; 2024 Gazetteer and cartographic boundary files. How we build these pages.