Get NSE price history, 50 and 200 day moving averages and volume for an Indian stock by name

View all Indian Stock Exchange API endpoints →

Returns historical series for one Indian stock, looked up by company name. stock_name is required (for example tcs), period is optional and accepts 1m, 6m, 1yr, 3yr, 5yr, 10yr or max with a documented default of 5yr, and filter is optional with a documented default of default. The documented filter values are price, pe, sm, evebitda, ptb, mcs and default; only price has been exercised in a probe. The observed probe call (stock_name=tcs, period=1m, filter=price) returned HTTP 200 with a JSON object whose single key, datasets, held four objects, each with label, meta, metric and values. The datasets were Price on NSE (metric Price, meta is_weekly=false), 50 DMA (metric DMA50), 200 DMA (metric DMA200) and Volume (metric Volume). In the probe, every values entry was an array starting with an ISO date (YYYY-MM-DD); price and moving-average values were strings with two decimals, while volume values were integers followed by an object with a delivery field that held a whole number or null. The 1m probe returned 20 data points per dataset. Longer periods, the max period and the other filter values were not probed, so their dataset lists and spacing are unverified. The endpoint documentation's example request uses symbol, but the declared parameter is stock_name, which is what the probe used. The data is informational and not an execution-grade tick feed.

API Features

Seven selectable history windows The period parameter accepts 1m, 6m, 1yr, 3yr, 5yr, 10yr and max, so one endpoint can serve a one-month sparkline and a long-range chart. The documented default is 5yr.
Self-describing datasets array Each entry in datasets carries a label, a meta object, a metric code and a values array, so a client can group series by metric instead of relying on fixed positions.
Price with 50 and 200 day averages The probe returned Price on NSE alongside 50 DMA (DMA50) and 200 DMA (DMA200) on the same dates, giving trend overlays without computing averages yourself.
Volume with delivery percentage The Volume dataset returns rows of date, traded volume and an object holding a delivery value, which was a whole number in most sampled rows and null on the first.
Optional filter for other series The filter parameter selects the dataset family. The documented values are price, pe, sm, evebitda, ptb, mcs and default; the probe verified price.
Company-name input for charts Pass stock_name such as tcs and receive chart-ready series without resolving an NSE ticker or BSE scrip code first.

Live API Demo

GET /api/project/indian-stock-exchange-api/historical-data

Request cost is temporarily unavailable. No price is assumed.

View pricing

API Response (JSON)

{}
curl -X GET 'https://api.opendata-api.com/api/project/indian-stock-exchange-api/historical-data?key=<API_KEY>&filter=default&period=5yr&stock_name=tcs'
📢
Need Help?
If you encounter API issues or need other API requirements, please contact us.
Contact Us

Use Cases

Frequently asked questions

What does the Historical Data endpoint return?

A JSON object with a datasets array. In a probe for tcs with period=1m and filter=price, it held four datasets, Price on NSE, 50 DMA, 200 DMA and Volume, each with label, meta, metric and values.

Which parameters does it take?

stock_name is required, for example tcs. period is optional and accepts 1m, 6m, 1yr, 3yr, 5yr, 10yr or max, with a documented default of 5yr. filter is optional and has a documented default of default.

The documentation example uses symbol. Which name should I use?

Use stock_name. The example request in the endpoint documentation shows symbol, but the declared required parameter is stock_name, and the probe call that returned HTTP 200 used stock_name=tcs.

What values can filter take?

The documentation lists price, pe, sm, evebitda, ptb, mcs and default. Only price was exercised in a probe, so the datasets returned for the other values are unverified; read each dataset's label and metric instead of assuming a fixed set.

How are dates and numbers formatted in values?

In the probe, each row started with an ISO date (YYYY-MM-DD). Price and moving-average figures were strings such as "2075.00", so convert them to numbers, while volume was already an integer.

What is the delivery field in the Volume dataset?

Volume rows had a third element, an object with a delivery key. In the probe it held a whole number in most rows and null in the first. It looks like a delivery percentage but the field is not documented, so treat it as an unverified extra.

Are all trading days present, and how big is the max period?

The 1m probe returned 20 dated rows per dataset with no weekend dates. The max period and the longer periods were not probed, so check meta.is_weekly and the date spacing in your own results, and cache large responses.

Related operations

Guides

View Subscription Plans →