Skip to content
MarketCalendars.com
Sign up

API documentation

REST API v2: trading hours, holidays and settlement days as JSON over HTTPS

Quick start

The MarketCalendars.com API returns trading hours, market holidays, irregular days and settlement days for 92 markets as JSON. Each request covers one market and one day, one year or one schedule, and each successful request counts as one. Your first 1,000 requests are free.

1. Create an API key

Sign in with your email address, then create a key under Account, API keys. The key is shown once. Store it as a secret, for example in an environment variable called MARKETCALENDARS_KEY. See Authentication.

2. Send a request

Send the key in the Authorization header. This request asks for the NYSE session on the day after Thanksgiving 2026:

curl https://marketcalendars.com/api/v2/markets/nyse/sessions/2026-11-27 \
  -H "Authorization: Bearer mc_live_..."

3. Read the response

Every phase has a start and end in ISO 8601 with the market's UTC offset, and the trade date it belongs to. The day isirregular because the market closes early, and reasons says why.

GET /api/v2/markets/nyse/sessions/2026-11-27200
{
  "market": "nyse",
  "tradeDate": "2026-11-27",
  "timezone": "America/New_York",
  "isTradingDay": true,
  "schedule": "irregular",
  "reasons": [
    {
      "type": "early_close",
      "name": "Day after Thanksgiving"
    }
  ],
  "isSettlementDay": true,
  "nonSettlementReason": null,
  "disputed": null,
  "phases": [
    {
      "type": "pre_market",
      "start": "2026-11-27T04:00:00-05:00",
      "end": "2026-11-27T09:30:00-05:00",
      "tradeDate": "2026-11-27"
    },
    {
      "type": "regular",
      "start": "2026-11-27T09:30:00-05:00",
      "end": "2026-11-27T13:00:00-05:00",
      "tradeDate": "2026-11-27"
    },
    {
      "type": "after_hours",
      "start": "2026-11-27T13:00:00-05:00",
      "end": "2026-11-27T17:00:00-05:00",
      "tradeDate": "2026-11-27"
    }
  ],
  "dataSource": "pandas_market_calendars 5.5.0"
}

Conventions

  • Base URL: https://marketcalendars.com/api/v2. HTTPS only, GET only, CORS enabled
  • Market ids are lower-case slugs such as nyse, lse or cme-equity-futures. GET /markets lists them all
  • Dates are YYYY-MM-DD and mean the market's own trade date, not a UTC date
  • Times are ISO 8601 with the market's UTC offset, such as 2026-11-27T13:00:00-05:00. Sessions that open the evening before (CME Globex) start on the previous calendar date and carry the next day's tradeDate
  • Data covers 1995-01-01 to 2051-12-31, depending on the market. Each market's coverage gives its own range, and the coverage page lists them all
  • Errors are RFC 9457 problem details

Endpoints

EndpointReturnsOne request
GET/marketsList marketsList
GET/markets/{market}Get a marketOne market
GET/markets/{market}/statusGet a market's status nowNow
GET/statusGet every market's status nowNow
GET/markets/{market}/sessions/{date}Get the session for a trade dateOne day
GET/markets/{market}/regular-hoursGet the regular weekly hoursOne schedule
GET/markets/{market}/trading-weekdaysGet the trading weekdaysOne schedule
GET/markets/{market}/holidays/{year}Get a year of holidaysOne year
GET/markets/{market}/irregular-days/{year}Get a year of irregular daysOne year
GET/markets/{market}/non-settlement-days/{year}Get a year of non-settlement daysOne year
GET/dates/{date}Get closures on a dateOne day
GET/openapi.jsonOpenAPI 3.1 documentFree, not counted

Generate a client from the OpenAPI document with any OpenAPI 3.1 tool, usinghttps://marketcalendars.com/api/v2 as the server.