SFOLN

Catalogue / Data utilities

Historical Weather Data API

sfoln/historical-weather · Developer tools, Automation, Travel On request

Get daily historical weather for any place or coordinates and date range since 1940: max, min and mean temperature, precipitation, rain, snowfall, wind and sunshine, one row per day (Open-Meteo). $0.20 per 1,000 days + $0.002 per location.

About

What it does

Historical Weather Data API gets daily historical weather – max/min/mean temperature, precipitation, rain, snowfall, max wind speed and sunshine duration – for any list of places or coordinates and any date range back to 1940. Each location-day is one clean dataset row, ready for spreadsheets, BI tools, insurance and claims checks, energy and retail demand models, agronomy and machine-learning features.

Price

Price per delivered record

EventPricePer 1,000Charged for
Historical weather day
historical-weather-day
$0.0002$0.20 / 1,000Charged once per location-day row delivered (days without data in the archive are not returned or charged).
Historical weather location
historical-weather-query
$0.002$2 / 1,000Charged once per location for which at least one day of history was delivered.

Apify free plan: up to 10 items per run. Paid plans have no per-run cap; set maxTotalChargeUsd to cap spend.

Run

Call it from code, an agent or the Console

This API is private on Apify for now. Email us and we will publish it for you, usually within two working days. The calls below work once it is public. contact@sfoln.com

curl · synchronous run, rows in the response
curl -X POST "https://api.apify.com/v2/actors/sfoln~historical-weather/run-sync-get-dataset-items" \
  -H "Authorization: Bearer $APIFY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"locations":["London"],"startDate":"2025-01-01","endDate":"2025-01-07"}'
mcp.json · hosted Apify MCP server
{
  "mcpServers": {
    "apify": {
      "type": "http",
      "url": "https://mcp.apify.com?tools=sfoln/historical-weather"
    }
  }
}
asynchronous run · for large batches
POST https://api.apify.com/v2/actors/sfoln~historical-weather/runs?maxTotalChargeUsd=1
GET  https://api.apify.com/v2/actor-runs/{runId}            # until status is SUCCEEDED
GET  https://api.apify.com/v2/datasets/{defaultDatasetId}/items?format=json

Authenticate with an Apify API token. MCP clients can instead sign in with OAuth when prompted. Example prompt for an agent: Get the daily weather in London from 1 to 7 January 2025: maximum and minimum temperature, rain and sunshine hours.

Input

Input fields

List places or coordinates and a date range. Each location produces one dataset row per day plus one per-location summary row.

FieldTypeDefaultMeaning
locations *arrayrequiredLocations
One per line: a place name ("London", "Paris, France") or "latitude,longitude" ("35.6762,139.6503"). Via the API you can also pass objects like {"latitude": 52.52, "longitude": 13.41, "name": "Site A"} or {"place": "Springfield", "countryCode": "US"}. Accounts on the Apify free plan can process up to 10 locations per run and 31 days per location.
startDate *stringrequiredStart date
First day (YYYY-MM-DD), 1940-01-01 or later.
endDatestring—End date
Last day (YYYY-MM-DD), inclusive. At most 366 days after the start date and not in the future. Defaults to the start date. The newest ~5 days are usually not in the archive yet.
variablesarray[]Daily variables
Which daily values to return. Leave empty for all.
unitsstring"metric"Units
metric = °C, km/h, mm (snowfall cm) · imperial = °F, mph, inch. One of "metric", "imperial".
maxLocationsinteger100Max locations
Safety cap on how many locations are processed in this run. Range 1–1000.
concurrencyinteger5Concurrency
How many locations are processed in parallel. Range 1–10.
includeRawbooleanfalseInclude raw upstream response
Attach the unmodified Open-Meteo payload to each per-location summary row.
Example input
{
  "locations": [
    "London"
  ],
  "startDate": "2025-01-01",
  "endDate": "2025-01-07"
}

Output

One record per input item

Records land in the run's dataset; a synchronous call returns them directly. Each has a status (ok is charged; everything else is free) and a charged flag. The run's OUTPUT record totals items and charges.

FieldTypeMeaning
inputstring | objectInput
The parsed location input.
recordTypestringRecord type
day = one billed row per location-day · location = per-location summary. e.g. "day"
locationstring | nullLocation
Resolved place label or "lat,lng".
resolvedPlaceobject | nullResolved place
Geocoding match for place-name inputs.
latitudenumber | nullLatitude
Grid-cell latitude used by the archive.
longitudenumber | nullLongitude
Grid-cell longitude used by the archive.
elevationnumber | nullElevation (m)
timezonestring | nullTimezone
Local timezone used to aggregate days.
datestringDate
Local calendar day (day rows). e.g. "2025-01-01"
tempMaxnumber | nullMax temperature
tempMinnumber | nullMin temperature
tempMeannumber | nullMean temperature
precipitationnumber | nullPrecipitation sum
rainnumber | nullRain sum
snowfallnumber | nullSnowfall sum
cm (metric) or inch.
windMaxnumber | nullMax wind speed (10 m)
sunshineDurationnumber | nullSunshine duration (s)
Seconds of sunshine (WMO definition).
unitsobject | nullUnits
Unit label per returned variable.
startDatestring | nullStart date (summary)
endDatestring | nullEnd date (summary)
daysRequestedinteger | nullDays requested (summary)
daysReturnedinteger | nullDays returned (summary)
attributionstring | nullAttribution
Weather data by Open-Meteo.com (CC BY 4.0).
statusstringStatus
ok | not_found | error | skipped_invalid | skipped_budget | skipped_free_plan e.g. "ok"
chargedbooleanCharged
Whether this record incurred a pay-per-event charge.
chargedEventstring | nullCharged event
sourcestringSource
openmeteo
fetchedAtstringFetched at
ISO timestamp.
Example record
{
  "input": {
    "kind": "place",
    "place": "London"
  },
  "recordType": "day",
  "location": "London, England, United Kingdom",
  "latitude": 51.493847,
  "longitude": -0.12354,
  "elevation": 23,
  "timezone": "Europe/London",
  "units": {
    "tempMax": "°C",
    "tempMin": "°C",
    "precipitation": "mm"
  },
  "attribution": "Weather data by Open-Meteo.com (CC BY 4.0)",
  "date": "2025-01-01",
  "tempMax": 11.2,
  "tempMin": 6.1,
  "precipitation": 3.4,
  "status": "ok",
  "charged": true,
  "chargedEvent": "historical-weather-day",
  "source": "openmeteo",
  "fetchedAt": "2026-10-14T10:00:00.000Z"
}

Machine-readable

This page for agents