India Market MCP
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@India Market MCP How did the market do today, and which sectors led?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
India Market MCP
An MCP server that gives Claude and other AI assistants live Indian market data: NSE quotes and indices, option chains with positioning analytics, company financials, shareholding, corporate actions, exchange filings and mutual fund performance. No API keys needed.
Ask things like:
"How did the market do today, and which sectors led?"
"Compare HDFC Bank and ICICI Bank on valuation, growth and promoter holding."
"What is NIFTY's option chain saying for this week's expiry? Where are the OI walls and max pain?"
"Show Parag Parikh Flexi Cap's 3, 5 and 10-year returns and its worst drawdown."
"What did Reliance announce to the exchange this month?"
Tools
Tool | What it returns |
| Market status, major indices and India VIX with 1w/1m/1y moves, NIFTY 50 P/E and P/B, sectors ranked by move, NIFTY 500 breadth, NIFTY 50 top movers, FII/DII net flows, USD/INR, upcoming holidays |
| NSE symbols (stocks, ETFs, SME) and indices matching a company or index name |
| Price, day range, VWAP, volume, delivery %, 52-week range, market cap, P/E vs sector P/E, sector, index membership. Index names return the index level, returns, P/E, P/B and breadth |
| OHLCV bars plus total return, CAGR, annualised volatility, max drawdown, 20/50/200-day averages, RSI, dividends and splits. Stocks, NSE indices and SENSEX |
| An index's level, returns, valuation and breadth, with every constituent's move, distance from its 52-week high and approximate weight |
| Strikes around the money with LTP, OI, change in OI, volume, IV, bid/ask and delta, plus put-call ratio, max pain, OI support and resistance, biggest OI build-ups, ATM IV, straddle-implied move and ATM Greeks |
| Black-Scholes price and Greeks, or implied volatility from a market price (works offline) |
| Annual or quarterly revenue, EBITDA, profit, EPS, margins, YoY growth, balance sheet, cash flow, ROE, debt/equity, current ratio, interest cover (₹ crore) |
| Promoter and public holding by quarter, with the promoter stake's QoQ and YoY change |
| Dividends (with amount per share), bonuses, splits, rights, buybacks, upcoming ex-dates, trailing 12-month dividend and yield |
| Exchange filings with a summary and PDF link, filterable by keyword |
| Scheme codes by name, filtered to direct/regular and growth/IDCW |
| Latest NAV, trailing returns (1 week to 10 years and since inception), calendar-year returns, 3-year volatility, max drawdowns |
The server also provides three prompts: research_stock, market_brief and options_positioning.
Related MCP server: nse-mcp
Set up
You need uv. It fetches the right Python and runs the server without a separate install step.
Claude Code
claude mcp add -s user india-market -- uvx --from git+https://github.com/kcodweb/india-market-mcp india-market-mcpClaude Desktop, Cursor, Windsurf and other clients. Add this to the client's MCP config (for Claude Desktop: Settings → Developer → Edit Config):
{
"mcpServers": {
"india-market": {
"command": "uvx",
"args": ["--from", "git+https://github.com/kcodweb/india-market-mcp", "india-market-mcp"]
}
}
}Restart the client and ask about the market.
From a clone
git clone https://github.com/kcodweb/india-market-mcp
cd india-market-mcp
uv sync
uv run india-market-mcp # stdio, for local clients
uv run india-market-mcp --transport streamable-http --port 8000 # HTTP at http://127.0.0.1:8000/mcpData sources
Data | Source | Freshness |
Quotes, indices, option chains, FII/DII, filings, shareholding, corporate actions | NSE website APIs | A few minutes delayed; cached 20 s |
Price history | Yahoo Finance | End of day, adjusted for splits and bonuses |
Financial statements | Yahoo Finance (from company filings) | Updated after results; the tool warns when the latest period looks stale |
Mutual fund NAVs | AMFI via mfapi.in | Daily |
How it works
NSE access. NSE's JSON endpoints sit behind bot protection. The server loads a normal page first to collect session cookies, sends browser-like headers, refreshes the session once if NSE answers 401/403, spaces its requests at least 350 ms apart and caches responses. It uses the endpoints NSE's current website calls, several of which replaced the older
/api/quote-equityfamily that NSE now blocks.Compact output. Results are small JSON documents: nulls dropped, money in ₹ crore, long lists capped with a note on how to see more. That keeps an assistant's context free for reasoning.
Errors the model can act on. A mistyped symbol returns suggestions (
RELIANC→ "Did you mean: RELIANCE (Reliance Industries Limited)…"), an unknown expiry lists the live ones, and a blocked request says why.Analytics in plain Python. Black-Scholes, Greeks, the implied-volatility solver, max pain, CAGR, drawdown, RSI and the rest have no NumPy or SciPy dependency, and all are unit-tested.
Limitations
These are unofficial website endpoints, not a licensed data feed. NSE changes them from time to time, and it blocks many cloud and non-Indian networks. Run the server on your own machine; a server in a US data centre will likely be refused.
Shareholding covers promoter and public totals only; NSE's summary does not break out FII, DII or mutual fund holdings.
Yahoo's statements for banks and financial companies are less complete than for other companies.
This is market data for research and education, not investment advice. Check the terms of use of NSE, Yahoo and AMFI before building anything commercial on it. Not affiliated with NSE, BSE, AMFI or Yahoo.
Development
uv sync # installs the dev tools too
uv run pytest # 118 offline tests, about a second
uv run pytest -m live # checks the real endpoints (run from an Indian connection)
uv run ruff check src tests && uv run ruff format --check src testsThe offline suite replays real responses recorded in tests/fixtures/, through a real MCP client, so it is
deterministic and never calls NSE from CI. To refresh the recordings, run python tests/record_fixtures.py
from a network NSE allows, update RECORDED_AT in tests/scenarios.py, and fix any assertions that depend
on the data.
src/india_market_mcp/
server.py tool and prompt definitions, CLI
features/ one module per area: market, history, derivatives, company, funds
sources/ HTTP clients for NSE, Yahoo Finance and mfapi.in
analytics/ option pricing and return statistics (pure functions)License
MIT
Available Tools
13 toolsget_announcementsCompany announcementsBRead-onlyIdempotent
Exchange filings from NSE (results, board meetings, acquisitions, credit ratings, investor meets...) with a short summary and a link to each PDF.
Inputs: symbol (required), days, limit, keyword.
get_corporate_actionsDividends, bonuses and splitsARead-onlyIdempotent
Corporate actions (dividends with amount per share, bonus issues, splits, rights, buybacks) with ex and record dates, upcoming ones flagged, plus dividends paid in the last 12 months and the trailing yield.
Inputs: symbol (required), limit.
get_financialsCompany financial statementsARead-onlyIdempotent
Reported revenue, EBITDA, operating profit, net profit and EPS with margins and year-on-year growth, plus balance sheet (assets, equity, debt, cash), cash flow (operating, capex, free cash flow) and ROE, debt/equity, current ratio and interest cover. Amounts in ₹ crore.
Inputs: symbol (required), count, period.
get_indexIndex details and constituentsBRead-onlyIdempotent
An NSE index's level, returns, valuation (P/E, P/B, dividend yield) and breadth, with every constituent's price, day/30-day/1-year change, distance from its 52-week high and approximate weight.
Inputs: index (required), limit, sort_by.
get_market_overviewMarket overviewARead-onlyIdempotent
Today's Indian market in one call: market open/closed, major indices and India VIX with 1-week, 1-month and 1-year changes, NIFTY 50 P/E and P/B, sector indices ranked by move, NIFTY 500 breadth, NIFTY 50 top gainers and losers, FII/DII net buying (₹ crore), USD/INR and upcoming market holidays.
Inputs: no named parameters.
get_mutual_fundMutual fund performanceBRead-onlyIdempotent
A scheme's latest NAV, category and fund house, trailing returns (1 week to 10 years and since inception, annualised beyond a year), calendar-year returns, 3-year volatility and maximum drawdowns.
Inputs: scheme_code (required).
get_option_chainOption chain with analyticsARead-onlyIdempotent
NSE option chain around the money, with put-call ratio (OI and volume), max pain, the strikes with the most call and put open interest (resistance/support), biggest OI build-ups, ATM implied volatility, the ATM straddle's implied move and Greeks. Also lists the live expiries.
Inputs: symbol (required), expiry, rate_pct, strikes_each_side.
get_price_historyPrice history and statisticsARead-onlyIdempotent
Historical OHLCV bars plus total return, CAGR, annualised volatility, max drawdown, period high/low, moving averages (20/50/200-day), RSI and dividends/splits. Statistics use adjusted prices.
Inputs: symbol (required), period, max_bars, bar_interval.
get_quoteStock or index quoteARead-onlyIdempotent
Latest price and day range, 52-week range, volume, delivery %, market cap, P/E vs sector P/E, sector and index membership for an NSE stock. Index names return the index level, returns, P/E, P/B and breadth.
Inputs: symbol (required).
price_optionBlack-Scholes option calculatorARead-onlyIdempotent
Price a European option and its Greeks (delta, gamma, theta per day, vega, rho, probability of expiring in the money), or give market_price to back out implied volatility. Works offline.
Inputs: spot (required), strike (required), option_type (required), days_to_expiry (required), +4 more.
search_mutual_fundsSearch mutual fundsARead-onlyIdempotent
Find Indian mutual fund schemes and their AMFI scheme codes (needed for get_mutual_fund).
Inputs: query (required), plan, limit, option.
search_securitiesSearch NSE securitiesARead-onlyIdempotent
Find NSE symbols for a company, ETF or index by name. Use this whenever the exact symbol is unknown.
Inputs: query (required), limit.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 13 tools
Tools cover distinct resource types (securities, options, mutual funds, financials), but index-level data is available from three tools (get_quote, get_index, get_market_overview) and dividend/split data appears in both get_price_history and get_corporate_actions. Descriptions help scope each tool, but an agent may still misselect for broad index or corporate action queries.
All names use snake_case with consistent verb_noun patterns: search_* for discovery, get_* for retrieval, and price_option as the only non-get verb. The single deviation is minor and still predictable.
13 tools cover equities, indices, options, mutual funds, and financials without obvious redundancy. Each tool adds a distinct capability within the Indian market data scope.
The surface is broad, covering search, quotes, history, options, financials, shareholding, corporate actions, announcements, and mutual funds. Minor gaps exist (e.g., mutual fund NAV history, futures, or deeper option analytics), but core workflows are supported.
Maintenance
Related MCP Connectors
Live crypto + IDX stock market intelligence for AI agents — 19 tools, no API key.
Market data, filings, fundamentals, macro, news and research runs for AI assistants.
Hosted MCP server for Indian NSE/BSE stock research: 59 tools for quotes, financials and ratios, peers, shareholding and pledge, filings with extracted facts, screens, F&O and FII/DII context. Source and freshness on every answer; no buy/sell calls.
Licensed Borsa Istanbul (BIST) data for AI assistants: live or 15-minute delayed prices, OHLCV bars from 1 minute to monthly, financial statements, ratios, KAP disclosures, indices and sectors, indicator backtests and portfolio tracking for 600+ Turkish stocks. OAuth sign-in with an istfin subscription. Never places orders.
Related MCP Servers
- AlicenseAqualityBmaintenanceIndian stock market (NSE & BSE) MCP server with 55 tools: live quotes, financials, technicals, a 326-ratio screener, FII/DII flows, option chains with IV, parsed annual reports and concall transcripts, IPOs and portfolio tracking for ~8,200 stocks.55229 npm147MIT
- FlicenseCqualityDmaintenanceEnables AI assistants to access National Stock Exchange of India (NSE) data, including live quotes, market status, indices, option chains, corporate actions, and historical data, through natural language.241-
- AlicenseAqualityCmaintenanceEnables AI assistants to query live NSE & BSE stock market data, with 55 tools covering quotes, financials, screeners, FII/DII flows, option chains, and company filings.55MIT
- FlicenseNot gradedqualityAmaintenanceEnables AI assistants to search, screen, and analyze 8,200+ NSE and BSE listed securities through 55 tools covering live quotes, financials, technical indicators, FII/DII flows, option chains, filings, IPOs, bulk deals, and portfolio P&L.-