12306-mcp

MCP server that searches China Railway 12306 tickets: schedules, train filters, transfers and intermediate stops

  • 2,429 ★ on the repository
  • Last commit
  • MIT
MCP server

Extended access

Why this level

  • Runs local code and makes network calls to the 12306 service
All reasons and checks

joooook/12306-mcp

Install

In your terminal, with SkillFoxx CLI

npx skillfoxx add mcp/12306-mcp

Detects the agents on your machine, shows the access level and pins the version.

Other ways to install

Access and checks

How we review

Extended accessThe tool runs code or makes network calls and only reads external data.

  • Runs local code and makes network calls to the 12306 service

This is third-party code. Review the repository files before installing.

What it does

The server exposes MCP tools that query the 12306 service and return structured train and ticket data. An agent can search trips between stations, filter trains by the attributes it needs, inspect a route with its intermediate stops and find options that require a transfer. Because results come back structured, the agent can compare and explain them further. It runs locally over stdio or as an http service, with no keys or account required.

Who it is for. For developers and agent users who need China Railway schedules and tickets straight from a chat.

Good fit when

  • You need to find trains and tickets between two stations in China
  • You need to check a route with intermediate stops or a transfer option
  • You need structured trip data for the agent to compare further

Not a fit when

  • You need to buy or book a ticket rather than just search
  • You need railways of countries other than China

Example request

Find morning trains from Beijing to Shanghai for tomorrow and show the travel time

MCP

Transport
stdio, http
Authentication
not required

Limitations

The server works only with the 12306 service and only for search; it does not buy or book. The author notes the project is for learning. It needs Node.js 18 or newer, and debugging via MCP Inspector 2.0.0 needs Node.js 22.19.0 or newer. Data availability depends on 12306 itself.

How to disable. Remove the 12306-mcp entry from your client's MCP configuration and restart it.

FAQ

Can I buy a ticket through the server?

No, the server only searches and shows train and ticket data; buying and booking are not supported.

Do I need a 12306 account or a key?

No, search does not require keys or an account login.

Discussion

No questions or reviews yet.

An MCP server for searching Chinese train tickets on 12306: availability, fares, stations, transfers and stops

MCP serverExtended access422Repository stars

An MCP server for Wanderlog: an agent creates and edits trip itineraries, places, hotels, transit, checklists and expenses.

MCP serverExtended access180Repository stars
Official

Hosted MCP server for finding cheap round-trip flights across flexible dates, no key or signup

MCP serverExtended access3Repository stars

Travelpayouts MCP server

travelpayouts-mcp

Russian stack

An MCP server for Travelpayouts, the company behind Aviasales: cheap flight search, a price calendar and hotels

MCP serverExtended access
Russian stack

An MCP server for Kaiten: cards, comments, spaces and boards with control over response verbosity

MCP serverBroad access33Repository stars
Official

Job search across company career pages through the Job Seek MCP server: filters, company data and prefilled watchlist links

MCP serverMinimal access225Repository stars

README in short

The README presents a 12306 ticket search server built on the Model Context Protocol. Listed features include ticket lookup, train filtering, intermediate stop queries and transfer queries. It shows how to run it: npx for stdio and http with a port, a Docker build and run, and an mcpServers config snippet. There is separate documentation on how it works and its architecture, and the author states the project is for learning. MIT licensed.

README badge

Report a problem