# Leis do Brasil

Leis do Brasil — an MCP server for Claude Code and other environments that provides access to the official text of over 1.2 million Brazilian legal norms. It uses a local SQLite index to retrieve exact citations and source links.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 71 repo stars
- Author: mazulo
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/mazulo/leis-mcp
- Updated: 2026-11-13
- Security check: automated, 2026-11-17 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/mcp/leis-do-brasil

## What it does

This tool enables AI agents to search and cite Brazilian legislation without relying on external search engines. It downloads a database of laws and runs locally, which speeds up data retrieval and enables offline access.

The server requires `uv` to manage dependencies. Installing `ripgrep` is recommended for efficient searching. Run `uvx leis-mcp index` before starting to download the necessary database.

## Requirements
- Needs: Python and uv (commands run via uvx)

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add leis-mcp -- uvx leis-mcp
```
uvx runs the command named after the package; if the README names another one, use uvx --from leis-mcp <command>

### Codex

**Platform CLI**
```bash
codex mcp add leis-do-brasil -- uvx leis-mcp
```
uvx runs the command named after the package; if the README names another one, use uvx --from leis-mcp <command>

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "leis-do-brasil": {
            "command": "uvx",
            "args": [
                "leis-mcp"
            ]
        }
    }
}
```
uvx runs the command named after the package; if the README names another one, use uvx --from leis-mcp <command>

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "leis-do-brasil": {
            "type": "stdio",
            "command": "uvx",
            "args": [
                "leis-mcp"
            ]
        }
    }
}
```
uvx runs the command named after the package; if the README names another one, use uvx --from leis-mcp <command>

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add leis-do-brasil uvx leis-mcp
```
uvx runs the command named after the package; if the README names another one, use uvx --from leis-mcp <command>

## When to use it
- retrieve exact text of a legal article
- verify the validity of a regulation
- get an official source link for a law
- cite specific legal provisions in documentation

## Example prompts
- Retrieve article 23 inciso III of law 8245/1991
- What does the LGPD say about data protection?
- Find regulations regarding residential leasing

## Similar
- [mcp-brasil-public-apis](https://affpapa.org/en/nevibecode/skills/mcp-brasil-public-apis.md) — skill · 880 installs
- [mcp-brasil-server](https://affpapa.org/en/nevibecode/skills/mcp-brasil-server.md) — skill · 225 installs
- [MCP Fiscal Brasil](https://affpapa.org/en/nevibecode/mcp/mcp-fiscal-brasil.md) — MCP server · ★ 436 repo stars
- [MCP Juridico Brasil](https://affpapa.org/en/nevibecode/mcp/mcp-juridico-brasil.md) — MCP server · ★ 143 repo stars
- [mcp-brasil-api](https://affpapa.org/en/nevibecode/mcp/mcp-brasil-api.md) — MCP server · ★ 279 repo stars
- [IBGE Brasil MCP](https://affpapa.org/en/nevibecode/mcp/ibge-brasil-mcp.md) — MCP server · ★ 14 repo stars

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
