# md-chunk-lite

> md-chunk-lite is an open-source MCP server for ai models and llm tooling. Split Markdown into heading-aware chunks for RAG, with paths and line numbers. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, Windows, macOS, Linux
- **Website:** https://tidybytetools.github.io/tools/markdown-chunker/
- **Repository:** https://github.com/tidybytetools/md-chunk-lite
- **MCP Registry name:** io.github.tidybytetools/md-chunk-lite
- **Categories:** AI models and LLM tooling, files and documents
- **Listing updated:** 2026-11-14

## About

Chunking here is plain code, not a model, so the same file always yields the same chunks. Each heading starts a new section, a small section becomes one chunk, and a large one is split at blank lines. Code blocks and tables stay whole when they fit, and chunk text is copied straight from the file so line numbers match.

Every chunk is a JSON line with an id such as guide.md#3, the source, a heading path like Garden Guide > Planting > Tomatoes, heading level, GitHub-style anchor, start and end lines, part and parts counters, and a character count. Options set a maximum size, print only the outline, or read from stdin.

It handles Markdown and plain text only, no PDF or Word. Install with pip, Python 3.10 or newer, MIT licensed. Paid options from the same maker: an Apify version at $0.0001 per chunk and a Gumroad tool for PDF, Word and HTML.

## Features

- **Heading-first splitting:** Chunks never mix two sections.
- **Whole code and tables:** Blocks are not cut in the middle when they fit.
- **Rich chunk metadata:** Heading path, anchor, line range, part counters and size.
- **Deterministic output:** No model is involved, so results repeat.
- **Outline mode:** Print just the headings with line numbers and sizes.

## Good for

- Prepare docs for embeddings and a RAG index
- Build a documentation search bot with linkable anchors
- Check how a Markdown file will be split before indexing
- Chunk many files into one JSONL

## Install

### Claude Code (Terminal)

```sh
claude mcp add md-chunk-lite -- uvx md-chunk-lite
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "md-chunk-lite": {
      "command": "uvx",
      "args": [
        "md-chunk-lite"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "md-chunk-lite": {
      "command": "uvx",
      "args": [
        "md-chunk-lite"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "md-chunk-lite": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "md-chunk-lite"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "md-chunk-lite": {
      "command": "uvx",
      "args": [
        "md-chunk-lite"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "md-chunk-lite": {
      "command": "uvx",
      "args": [
        "md-chunk-lite"
      ]
    }
  }
}
```

## FAQ

### Does it use AI to split text?

No. It is deterministic code.

### Can it read PDFs?

No, only Markdown and plain text.

### What does each chunk contain?

Id, source, index, heading path, level, anchor, line range, part, parts, size and text.

### Is there a paid option?

Apify charges $0.0001 per chunk, and a separate Gumroad tool covers PDF and Word.

### Is md-chunk-lite free?

Yes. md-chunk-lite is open source, so you can use and self-host it for free.

### How do I add md-chunk-lite to Claude Code?

Run this command in your terminal: claude mcp add md-chunk-lite -- uvx md-chunk-lite

### What are the best alternatives to md-chunk-lite?

The closest alternatives to md-chunk-lite are Claude Code Ultimate Guide, ASTra, CARTESIAN ECU, Invoices and SigPen.

## Alternatives

- [Claude Code Ultimate Guide](https://ai-powered.com/mcp/claude-code-ultimate-guide): Claude Code Ultimate Guide is an open-source MCP server for ai models and llm tooling.
- [ASTra](https://ai-powered.com/mcp/astra): ASTra is a freemium MCP server for files and documents.
- [CARTESIAN ECU](https://ai-powered.com/mcp/cartesian-ecu): CARTESIAN ECU is a paid MCP server for files and documents.
- [Invoices](https://ai-powered.com/mcp/invoices): Invoices is a paid MCP server for files and documents.
- [SigPen](https://ai-powered.com/mcp/sigpen): SigPen is a freemium MCP server for files and documents.
- [ConvertAudioToText](https://ai-powered.com/mcp/convertaudiototext): ConvertAudioToText is a freemium MCP server for design and media.
- [signafAIde](https://ai-powered.com/mcp/signafaide): signafAIde is a freemium MCP server for security.
- [Toolkien](https://ai-powered.com/mcp/toolkien): Toolkien is an open-source MCP server for ai models and llm tooling.

---
Source: https://ai-powered.com/mcp/md-chunk-lite
