noaa_coops

A Python wrapper for the NOAA CO-OPS Tides & Currents Data and Metadata APIs.
https://github.com/gclunies/noaa_coops

Category: Hydrosphere
Sub Category: Ocean and Hydrology Data Access

Keywords

coops currents metocean noaa python sensors-data tides water-level weather-api

Keywords from Contributors

numerical-modeling

Last synced: about 4 hours ago
JSON representation

Repository metadata

A Python wrapper for the NOAA CO-OPS Tides & Currents Data and Metadata APIs.

README.md

noaa_coops

CI
PyPI
PyPI - Python Version
License: Apache 2.0
Ruff
pre-commit.ci status

A Python wrapper for the NOAA CO-OPS Tides & Currents
Data and
Metadata APIs.

Installation

Supported on Python 3.10, 3.11, 3.12, and 3.13.

uv add noaa-coops

Or with pip:

pip install noaa-coops

Getting started

Stations

Data is accessed via Station objects identified by a NOAA station id:

>>> from noaa_coops import Station
>>> seattle = Station(id="9447130")  # Seattle, WA

Find station IDs via the NOAA
Tides & Currents mapping interface or
search by bounding box:

>>> from noaa_coops import get_stations_from_bbox, Station
>>> stations = get_stations_from_bbox(
...     lat_coords=[40.389, 40.9397],
...     lon_coords=[-74.4751, -73.7432],
... )
>>> stations
['8516945', '8518750', '8531680']
>>> Station(id="8516945").name
'Kings Point'

Metadata

Station metadata lives on the .metadata attribute, and individual fields are
also promoted to top-level attributes on the Station object:

>>> seattle = Station(id="9447130")
>>> seattle.name
'Seattle'
>>> seattle.state
'WA'
>>> seattle.lat_lon
{'lat': 47.60264, 'lon': -122.3393}

Data inventory

Per-product first/last observation dates:

>>> seattle.data_inventory["Wind"]
{'start_date': '1991-11-09 00:00', 'end_date': '...'}

Note: The data inventory comes from NOAA's legacy SOAP endpoint and is
best-effort. If the service is unreachable, data_inventory is set to {}
and a warning is logged — Station() construction still succeeds.

Data retrieval

Data is returned as a pandas DataFrame indexed by timestamp. Column names
mirror NOAA's response format.

>>> seattle = Station(id="9447130")
>>> df = seattle.get_data(
...     begin_date="20150101",
...     end_date="20150131",
...     product="water_level",
...     datum="MLLW",
...     units="metric",
...     time_zone="gmt",
... )
>>> df.head()
                         v      s        f  q
t
2015-01-01 00:00:00  1.799  0.023  0,0,0,0  v
2015-01-01 00:06:00  1.718  0.018  0,0,0,0  v
2015-01-01 00:12:00  1.639  0.013  0,0,0,0  v
2015-01-01 00:18:00  1.557  0.012  0,0,0,0  v
2015-01-01 00:24:00  1.473  0.014  0,0,0,0  v

Water levels chart

Multi-month and multi-year ranges are automatically split into 31-day (or
365-day for hourly_height / high_low) blocks and concatenated. If NOAA
fails to return data for a block, you get a partial DataFrame along with a
RuntimeWarning and a df.attrs["missing_blocks"] list describing which
ranges failed — downstream code can detect gaps instead of silently averaging
across them.

Supported arguments

Values accepted by Station.get_data(...) — see
NOAA's API docs for
the authoritative reference.

Argument Accepted values
product water_level, hourly_height, high_low, daily_mean, monthly_mean, one_minute_water_level, predictions, datums, air_gap, air_temperature, water_temperature, wind, air_pressure, conductivity, visibility, humidity, salinity, currents, currents_predictions, ofs_water_level
datum CRD, IGLD, LWD, MHHW, MHW, MTL, MSL, MLW, MLLW, NAVD, STND (case-insensitive). Required for water-level products.
units metric, english
time_zone gmt, lst, lst_ldt
bin_num Integer. Required for currents and currents_predictions. Find values on each station's info page.
interval Product-specific. predictions: h, 1, 5, 10, 15, 30, 60, hilo. currents: 6, h. currents_predictions: h, 1, 6, 10, 30, 60, max_slack. Forbidden on water_level, hourly_height, one_minute_water_level.

Accepted date formats

begin_date and end_date accept any of:

  • "20150101"%Y%m%d
  • "20150101 12:34"%Y%m%d %H:%M
  • "01/15/2015"%m/%d/%Y
  • "01/15/2015 23:59"%m/%d/%Y %H:%M

API etiquette

NOAA's CO-OPS APIs are public and free. There are no enforced rate limits but
please be reasonable — avoid tight loops against a single station and cache
results when you can. This library uses connection pooling and automatic
retries on transient failures (429 / 5xx) via a module-level
requests.Session.

Contributing

Bug reports, feature requests, and PRs welcome. See
CONTRIBUTING.md for dev-environment setup and the release
workflow.

Citation (CITATION.cff)

cff-version: 1.2.0
title: noaa_coops
message: "If you use this software, please cite it as below."
type: software
version: "0.5.0"
authors:
  - family-names: Clunies
    given-names: Gregory
    github: GClunies
repository-code: "https://github.com/GClunies/noaa_coops"
url: "https://github.com/GClunies/noaa_coops"
license: Apache-2.0
abstract: >
  A Python wrapper for the NOAA CO-OPS Tides & Currents data APIs,
  enabling easy access to oceanographic and tidal data.
keywords:
  - NOAA
  - tides
  - currents
  - oceanography
  - python
  - API

Owner metadata


GitHub Events

Total
Last Year

Committers metadata

Last synced: 19 days ago

Total Commits: 176
Total Committers: 12
Avg Commits per committer: 14.667
Development Distribution Score (DDS): 0.119

Commits in past year: 25
Committers in past year: 6
Avg Commits per committer in past year: 4.167
Development Distribution Score (DDS) in past year: 0.2

Name Email Commits
Greg Clunies g****s@g****m 155
Kim Pevey k****y@g****m 7
Kristen Thyng k****g@g****m 4
taataam t****i@g****m 2
wrightky k****t@u****u 1
monika128 m****8@g****m 1
dependabot[bot] 4****] 1
Swayam Agrawal S****n@g****m 1
Sakshi Rohida s****6@g****m 1
Marc Mueller 3****p 1
Jacob Shufro j****b@s****o 1
Craig Harter c****r@m****m 1

Committer domains:


Issue and Pull Request metadata

Last synced: 17 days ago

Total issues: 33
Total pull requests: 50
Average time to close issues: 3 months
Average time to close pull requests: about 2 months
Total issue authors: 18
Total pull request authors: 14
Average comments per issue: 1.27
Average comments per pull request: 0.7
Merged pull request: 32
Bot issues: 1
Bot pull requests: 8

Past year issues: 10
Past year pull requests: 4
Past year average time to close issues: 6 months
Past year average time to close pull requests: about 8 hours
Past year issue authors: 5
Past year pull request authors: 4
Past year average comments per issue: 0.3
Past year average comments per pull request: 0.75
Past year merged pull request: 1
Past year bot issues: 1
Past year bot pull requests: 0

More stats: https://issues.ecosyste.ms/repositories/lookup?url=https://github.com/gclunies/noaa_coops

Top Issue Authors

  • GClunies (9)
  • salme146 (5)
  • wrightky (3)
  • kthyng (2)
  • Russ-Nasrallah (1)
  • dianamJLAB (1)
  • MehdiArmandei (1)
  • sdat2 (1)
  • DanRamage (1)
  • mauroc (1)
  • jbouwh (1)
  • github-actions[bot] (1)
  • cheginit (1)
  • ArchiHowlader (1)
  • Manish-Singh-Mehra (1)

Top Pull Request Authors

  • GClunies (27)
  • dependabot[bot] (8)
  • kthyng (3)
  • kcpevey (2)
  • cdce8p (1)
  • CraigHarterMM (1)
  • bkposton (1)
  • alexander0042 (1)
  • monika-2906-git (1)
  • srpeiter (1)
  • SakshiiRohida (1)
  • cheginit (1)
  • jshufro (1)
  • sdat2 (1)

Top Issue Labels

  • enhancement (5)
  • bug (3)
  • nightly-canary (1)
  • epic (1)

Top Pull Request Labels

  • dependencies (8)

Package metadata

proxy.golang.org: github.com/gclunies/noaa_coops

  • Homepage:
  • Documentation: https://pkg.go.dev/github.com/gclunies/noaa_coops#section-documentation
  • Licenses: apache-2.0
  • Latest release: v0.2.1 (published over 3 years ago)
  • Last Synced: 2026-04-25T09:37:50.700Z (18 days ago)
  • Versions: 5
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Dependent packages count: 6.999%
    • Average: 8.173%
    • Dependent repos count: 9.346%
proxy.golang.org: github.com/GClunies/noaa_coops

  • Homepage:
  • Documentation: https://pkg.go.dev/github.com/GClunies/noaa_coops#section-documentation
  • Licenses: apache-2.0
  • Latest release: v0.2.1 (published over 3 years ago)
  • Last Synced: 2026-04-25T09:37:53.888Z (18 days ago)
  • Versions: 5
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Dependent packages count: 6.999%
    • Average: 8.173%
    • Dependent repos count: 9.346%
conda-forge.org: noaa-coops

  • Homepage: https://github.com/GClunies/noaa_coops
  • Licenses: GPL-3.0-or-later
  • Latest release: 0.1.9 (published over 3 years ago)
  • Last Synced: 2026-04-02T20:36:57.752Z (about 1 month ago)
  • Versions: 1
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Forks count: 33.247%
    • Dependent repos count: 34.025%
    • Stargazers count: 39.052%
    • Average: 39.375%
    • Dependent packages count: 51.175%
nixpkgs-unstable: python314Packages.noaa-coops

Python wrapper for NOAA CO-OPS Tides & Currents Data and Metadata APIs

nixpkgs-unstable: python313Packages.noaa-coops

Python wrapper for NOAA CO-OPS Tides & Currents Data and Metadata APIs


Dependencies

.github/workflows/pre_release.yml actions
  • JRubics/poetry-publish v1.16 composite
  • actions/checkout v3 composite
.github/workflows/pull_request.yml actions
  • actions/cache v3 composite
  • actions/checkout v3 composite
  • actions/setup-python v4 composite
  • snok/install-poetry v1 composite
.github/workflows/release.yml actions
  • JRubics/poetry-publish v1.16 composite
  • actions/checkout v3 composite
poetry.lock pypi
  • arrow 1.2.3 develop
  • autoflake 2.0.1 develop
  • binaryornot 0.4.4 develop
  • black 23.1.0 develop
  • boolean-py 4.0 develop
  • cachetools 5.3.0 develop
  • chardet 5.1.0 develop
  • click 8.1.3 develop
  • colorama 0.4.6 develop
  • darglint 1.8.1 develop
  • distlib 0.3.6 develop
  • exceptiongroup 1.1.0 develop
  • filelock 3.9.0 develop
  • flake8 6.0.0 develop
  • flake8-docstrings 1.7.0 develop
  • iniconfig 2.0.0 develop
  • isort 5.12.0 develop
  • jinja2 3.1.2 develop
  • jinja2-time 0.2.0 develop
  • license-expression 30.1.0 develop
  • make 0.1.6.post2 develop
  • markupsafe 2.1.2 develop
  • mccabe 0.7.0 develop
  • mypy-extensions 1.0.0 develop
  • packaging 23.0 develop
  • pathspec 0.11.0 develop
  • pluggy 1.0.0 develop
  • pycodestyle 2.10.0 develop
  • pydocstyle 6.3.0 develop
  • pyflakes 3.0.1 develop
  • pyproject-api 1.5.0 develop
  • pytest 7.2.1 develop
  • python-debian 0.1.49 develop
  • reuse 1.1.1 develop
  • setuptools 67.1.0 develop
  • snowballstemmer 2.2.0 develop
  • toml 0.10.2 develop
  • tomli 2.0.1 develop
  • tox 4.4.4 develop
  • typing-extensions 4.4.0 develop
  • virtualenv 20.17.1 develop
  • attrs 22.2.0
  • certifi 2022.12.7
  • charset-normalizer 3.0.1
  • idna 3.4
  • isodate 0.6.1
  • lxml 4.9.2
  • numpy 1.24.1
  • pandas 1.5.3
  • platformdirs 2.6.2
  • python-dateutil 2.8.2
  • pytz 2022.7.1
  • requests 2.28.2
  • requests-file 1.5.1
  • requests-toolbelt 0.10.1
  • six 1.16.0
  • urllib3 1.26.14
  • zeep 4.2.1
pyproject.toml pypi
  • numpy ^1.24.1
  • pandas ^1.5.3
  • python ^3.8
  • requests ^2.28.2
  • zeep ^4.2.1

Score: 7.069874128458572