CustomWeather offers on-demand, real-time forecasts and observational data from dozens of forecast and reanalysis models via the Cloud Weather Service (CWS) API.
Key features include:
Access to the CWS API requires a username and password. If you would like to request access, click here. CustomWeather offers competitive, flexible pricing plans. For more information, contact us.
Returns the requested variables in either XML or JSON format.
http://cws.customweather.com/data?client=sampleuser&client_password=samplepassword
| Parameter | Required | Description |
|---|---|---|
| client | yes | Username provided by CustomWeather. |
| client_password | yes | Password provided by CustomWeather. IP address authentication also available without a password. |
| layer | yes | The model name, variable name and level name. Each name must be seperated by a colon (model_name:variable:level). Model data information will be provided by CustomWeather. |
| init_time | Required only for forecast data, but not required for historical data. | The model time in ISO 8601 format: YYYY-MM-DDThh:mm:ss. Specifying "latest" will return the latest model run available. |
| start | yes | The forecast time integer. If start is omitted, 0 (forecast hour zero) will be assumed. For historical data please see notes below. |
| end | yes | The forecast end time integer. For historical data please see notes below. |
| id | Required but can only be used one at a time. | The CustomWeather city ID. A city list will be sent if needed and after a contract has been signed. Sample IDs may be available upon request. More than one ID can be requested by separating the IDs by a comma. |
| latitude | Required but can only be used one at a time. | The latitude decimal coordinates. Must be used concomitantly with the longitude parameter. |
| longitude | Required but can only be used one at a time. | The longitude decimal coordinates. Must be used concomitantly with the latitude parameter. |
| zip_code | Required but can only be used one at a time. | The US zip code. |
| metric | Optional | Toggle switch for the unit system desired. “metric=false” will return the data in Imperial units (Fahrenheit, mph, inches, etc.). The default units is Metric (Celsius, km/h, centimeters, etc.) |
| format | Optional | "json" if JSON format is required. |
| time_format | Optional | The custom date format in ISO 8601 format: YYYY-MM-DDTHH:MM:SS. |
Three variables at three levels for one location for hours 0-6 from the 2017-01-02 00Z model run in JSON format
http://cws.customweather.com/data?client=sampleuser&client_password=samplepassword&layer=gfs0p25:windspeed:80m&layer=gfs0p25:maxtemp:2m&layer=gfs0p25:temp:850hPa&init_time=2017-01-02T00:00:00&start=0&end=6&metric=false&latitude=42.62006&longitude=1.53988&format=json
Two locations, one variable at one level for hours 120-168 from the latest model run
https://cws.customweather.com/data?client=sampleuser&client_password=samplepassword&layer=gfs0p25:temp:sfc&init_time=latest&start=120&end=168&id=KSFO,KSAN
Monthly Forecast Data
Four variables for months 0-5 from the latest model run with a custom time format
https://cws.customweather.com/data?client=sampleuser&client_password=samplepassword&layer=cfsv2_forecast_1day:meantemp:2m&layer=cfsv2_forecast_1day:windspeed:10m&layer=cfsv2_forecast_1day:dewpoint:2m&layer=cfsv2_forecast_1day:relhum:2m&init_time=latest&id=77201&start=0&end=5&time_format=yyyy-MM-dd'T'HH:mmz&metric=true
Historical Daily Data
One location, one variable for 1-1-2017 to 1-31-2017
http://xml.customweather.com/data?client=sampleuser&client_password=samplepassword&layer=era_daily_obs:maxtemp:2m&start=2017-01-00T00:00&end=2017-01-31T23:00&latitude=39.71702&longitude=-104.9548767&metric=false
| Field | Description |
|---|---|
| metric | Metric units indicator (true or false). |
| nearest_city_name | Name of nearest city to the data point. |
| latitude | The latitude coordinates in decimal degrees of the requested location. |
| longitude | The longitude coordinates in decimal degrees of the requested location. |
| tzinfo | IANA (Internet Assigned Numbers Authority) time zone database identifier. |
| elevation | The elevation of the location in meters or feet. |
| timezone | Time zone offset from UTC of the location. |
| state | The state code of the reporting station. |
| state_name | The state name of the reporting station. |
| country | The country code of the reporting station. |
| iso_cc | The ISO country code of the reporting station. |
| country_name | The country name. |
| local_time | The real-time local time of the location in %a, %d %b %Y %I:%M:%S %Z format. |
| localupdatetime | The time of the last update in %a, %d %b %Y %I:%M:%S %Z format. |
| name | The name of the API. |
| id | The product name of the forecast model layer. |
| name | The full name of the requested forecast model. |
| res_deg | The resolution of the forecast model in degrees. |
| res_km | The resolution of the forecast model in kilometers. |
| res_time | The temporal resolution of the forecast model. |
| init_utc | The UTC date and time of the forecast day in ISO 8601 format. |
| init_local | The local date and time of the forecast day in ISO 8601 format. |
| utc | The UTC date and time the variable is valid for in ISO 8601 format. |
| local | The local time and date the data is valid for in ISO 8601 format. |
| name [variable] | The name of the variable. |
| level | The level name of the variable. |
| description | The text description of the variable. |
| units | The units of the variable. |
| data | The numerical data of the variable. |
| units [period] | The time resolution units. |
Returns a map for the selected variable.
http://cws.customweather.com/image?client=sampleuser&client_password=samplepassword
| Parameter | Required | Description |
|---|---|---|
| client | yes | Username provided by CustomWeather. |
| client_password | yes | Password provided by CustomWeather. IP address authentication also available without a password. |
| layer | yes | The model name, variable name and level name. Each name must be seperated by a colon (model_name:variable:level). Model data information will be provided by CustomWeather. |
| init_time | yes | The model time in ISO 8601 format: YYYY-MM-DDTHH:MM:SS. Specifying "latest" will return the latest model run available. For historical data, the date/time in 8601 format: YYYY-MM-DDTHH:MM:SS. |
| forecast_hour | yes | The forecast time. If start is omitted, 0 (forecast our zero) will he assumed. |
| bbox | yes | Bounding box specified by latitude/longitude coordinates (minx,miny,maxx,maxy). |
| width | yes | Width of image in number of pixels. Height is calculated from bbox. |
| metric | Optional | Toggle switch for the unit system desired. “metric=false” will return the data in Imperial units (Fahrenheit, mph, inches, etc.). The default units is Metric (Celsius, km/h, centimeters, etc.) |
| format | Optional | "image/jpeg" for JPEG format. "image/gif" for GIF format. "image/png" for PNG format (default). |
| features | Optional | Map layers (world_borders, state_borders, counties, coasts, base). |
One variable for hour 3 for the world with the coasts layer at 2400 pixels
http://cws.customweather.com/image?client=sampleuser&client_password=samplepassword&layer=gfs0p25hourly:mintemp:2m&init_time=latest&forecast_hour=3&BBOX=-180,-90,180,90&features=coasts&width=2400
One variable for a bounding box of 100,0,-60,40 with the world borders layer at 1000 pixels
http://cws.customweather.com/image?client=sampleuser&client_password=samplepassword&layer=trmm10km:precip:sfc&init_time=latest&BBOX=-100,0,-60,40&features=world_borders&width=1000
Historical Data (see sample image below)
Estimated daily observations for the US at 1000 pixels for December 12, 2022
https://cws.customweather.com/image?client=sampleuser&client_password=samplepassword&layer=era_daily_obs:maxtemp:2m&init_time=2022-12-09T00:00&BBOX=united_states&WIDTH=1000&format=image/jpeg
Only one variable and one forecast hour or past time can be requested at a time.
Returns a NetCDF file for the requested variable.
http://cws.customweather.com/netcdf?client=sampleuser&client_password=samplepassword
| Parameter | Required | Description |
|---|---|---|
| client | yes | Username provided by CustomWeather. |
| client_password | yes | Password provided by CustomWeather. IP address authentication also available without a password. |
| layer | yes | The model name, variable name and level name. Each name must be seperated by a colon (model_name:variable:level). Model data information will be provided by CustomWeather. |
| init_time | yes | The model time in ISO 8601 format: YYYY-MM-DDThh:mm:ss. Specifying "latest" will return the latest model run available. For historical data, the date/time in 8601 format: YYYY-MM-DDTHH:MM:SS. |
| forecast_hour | yes | The forecast time. If start is omitted, 0 (forecast our zero) will he assumed. |
| bbox | yes | Bounding box specified by latitude/longitude coordinates (minx,miny,maxx,maxy). |
| width | yes | Width of image in number of pixels. Height is calculated from bbox. |
One variable for hour 10 for bounding box -120,35,-75,50 at 500 pixels
http://cws.customweather.com/netcdf?client=&client_password=&layer=hrrrsfc3km:temp:sfc&init_time=latest&bbox=-120,35,-75,50&forecast_hour=10&width=500
One variable for hour 3 for the world at 1000 pixels (see sample file below)
http://cws.customweather.com/netcdf?client=sampleuser&client_password=samplepassword&layer=gfs0p25hourly:mintemp:2m&init_time=latest&forecast_hour=3&BBOX=-180,-90,180,90&features=coasts&width=1000
Historical Data
Estimated daily observations for the US at 1000 pixels for December 12, 2022
https://cws.customweather.com/netcdf?client=sampleuser&client_password=samplepassword&layer=era_daily_obs:maxtemp:2m&init_time=2022-12-09T00:00&BBOX=united_states&WIDTH=1000
Only one variable and one forecast hour or past time can be requested at a time.
Returns a point data file for the requested variable.
http://cws.customweather.com/ascii?client=sampleuser&client_password=samplepassword
| Parameter | Required | Description |
|---|---|---|
| client | yes | Username provided by CustomWeather. |
| client_password | yes | Password provided by CustomWeather. IP address authentication also available without a password. |
| layer | yes | The model name, variable name and level name. Each name must be seperated by a colon (model_name:variable:level). Model data information will be provided by CustomWeather. |
| init_time | yes | The model time in ISO 8601 format: YYYY-MM-DDThh:mm:ss. Specifying "latest" will return the latest model run available. For historical data, the date/time in 8601 format: YYYY-MM-DDTHH:MM:SS. |
| forecast_hour | yes | The forecast time. If start is omitted, 0 (forecast our zero) will he assumed. |
| bbox | yes | Bounding box specified by latitude/longitude coordinates (minx,miny,maxx,maxy). |
| width | yes | Number of horizontal data points. Height is calculated from the BBOX. |
One variable for bounding box -100,50,-90,40 for forecast hour 12 at 1200 horizontal data points
https://cws.customweather.com/ascii?client=sampleuser&client_password=samplepassword&layer=gfs0p25:temp:sfc&init_time=latest&forecast_hour=12&bbox=-100,50,-90,40&width=1200
One variable for a bounding box of 100,0,-60,40 with the world borders layer at 1000 horizontal data points (see sample output below).
https://cws.customweather.com/ascii?client=sampleuser&client_password=samplepassword&layer=ecmwf0p25_det:precip_acc:sfc&init_time=latest&BBOX=-100,0,-60,40&features=world_borders&width=1000
| Field | Description |
|---|---|
| ASCII Output | -100.0000 40.0000 0.0006 -99.9600 40.0000 0.0006 -99.9200 40.0000 0.0005 -99.8800 40.0000 0.0004 -99.8400 40.0000 0.0004 -99.8000 40.0000 0.0003 -99.7600 40.0000 0.0002 -99.7200 40.0000 0.0002 -99.6800 40.0000 0.0002 -99.6400 40.0000 0.0001 -99.6000 40.0000 0.0001 -99.5600 40.0000 0.0001 -99.5200 40.0000 0.0001 -99.4800 40.0000 0.0000 -99.4400 40.0000 0.0000 -99.4000 40.0000 0.0000 -99.3600 40.0000 0.0000 -99.3200 40.0000 0.0000 -99.2800 40.0000 0.0000 -99.2400 40.0000 0.0000 -99.2000 40.0000 0.0000 -99.1600 40.0000 0.0001 -99.1200 40.0000 0.0001 -99.0800 40.0000 0.0001 -99.0400 40.0000 0.0001 |
Only one variable and one forecast hour or past time can be requested at a time.