ChatGPT2LocalBridge

ChatGPT2LocalBridge

Self-hosted MCP server that enables ChatGPT to access and operate on local project files after OAuth authorization, without uploading the workspace elsewhere.

Category
Visit Server

README

<div align="center"> <img src="./docs/assets/logo.png" alt="ChatGPT2LocalBridge logo" width="180" /> <h1>ChatGPT2LocalBridge</h1> <p><strong>OAuth MCP Connector for approved local files.</strong></p> <p> <img alt="License" src="https://img.shields.io/badge/license-MIT-blue.svg" /> <img alt="Node" src="https://img.shields.io/badge/node-%3E%3D20-339933.svg" /> <img alt="MCP" src="https://img.shields.io/badge/MCP-Streamable%20HTTP-1769e0.svg" /> <img alt="Status" src="https://img.shields.io/badge/status-alpha-f59e0b.svg" /> </p> <p> <a href="./docs/index.html">Pages source</a> · <a href="./docs/showcase.html">Showcase</a> · <a href="./docs/human-tutorial.html">Human tutorial</a> · <a href="./docs/agent-computer-use.html">Agent tutorial</a> · <a href="./docs/alternatives.md">Alternatives</a> · <a href="./docs/sync-flows.md">Sync flows</a> </p> </div>

ChatGPT2LocalBridge cover

<!-- showcase:start --> <p align="center"> <img src="./docs/assets/thumbnail-responsive.png" alt="ChatGPT2LocalBridge responsive preview" width="900" /> </p> <!-- showcase:end -->

ChatGPT2LocalBridge is a self-hosted MCP server that lets ChatGPT access approved local workspaces after OAuth authorization. It is designed for people who want ChatGPT to inspect or operate on local project files without uploading the whole workspace elsewhere.

It is not a legacy ChatGPT plugin. It is best described as:

  • MCP Server
  • ChatGPT Custom Connector
  • OAuth Local Workspace Bridge

Unofficial project. Not affiliated with OpenAI.

Route

ChatGPT
  -> OAuth MCP Connector
  -> HTTPS tunnel
  -> http://127.0.0.1:3838/mcp
  -> ChatGPT2LocalBridge
  -> approved local workspace roots

ChatGPT does not directly mount your disk. It calls MCP tools, and every file operation is checked against bridge.policy.json.

30-Second Install

npx github:harzva/chatgpt2localbridge init --root ~/Projects
set -a; source .env.local; set +a
npx github:harzva/chatgpt2localbridge --http 3838

Local clone flow:

git clone https://github.com/harzva/chatgpt2localbridge.git
cd chatgpt2localbridge
npm install
npm run build
node dist/index.js init --root ~/Projects
set -a; source .env.local; set +a
node dist/index.js --http 3838

Health check:

curl -sS http://127.0.0.1:3838/health

Local operator console:

http://127.0.0.1:3838/app

ChatGPT Connector Setup

Expose the local server through HTTPS:

ngrok http 3838 --url=your-fixed-domain.ngrok-free.dev

Then create a ChatGPT Custom Connector:

Field Value
Name ChatGPT2LocalBridge
URL https://your-fixed-domain.ngrok-free.dev/mcp
Auth OAuth

When the authorization page opens, enter the unlock code from .env.local. Do not paste unlock codes or tokens into public chats, issues, screenshots, or commits.

Screenshot Walkthrough

Step Preview
Initialize local policy Initialize
Run local MCP server Run
Check /health Health
Create connector Connector
Authorize Authorize
Test file listing Success

Full guides:

Main MCP Tools

Area Examples
Project project.snapshot, project.index, project.scripts
Code code.read, code.read_range, code.search
Files file.list, file.stat, file.write, file.patch, file.delete
Shell/tests shell.exec, test.detect, test.run
Git git.status, git.diff, git.checkpoint, git.revert
Runtime workspace.*, task.*, process.*, port.check
Cloud sync cloud.download
Bridge bridge.status, bridge.health, bridge.logs, bridge.activity, service.restart

File Sync And Activity

  • Local files can be read by ChatGPT through approved MCP tools.
  • ChatGPT/App-provided cloud file download URLs can be written back to local disk with cloud.download.
  • Tool calls are persisted to tool-calls.jsonl.
  • File writes, downloads, tasks, processes, and service restarts are persisted to audit.jsonl.
  • The local console at /app shows status, tool calls, and audit events.

See file sync flows.

Security Defaults

  • Do not run unauthenticated on a public URL.
  • Keep allowedProjectRoots narrow.
  • Never commit .env.local, bridge.policy.json, OAuth stores, tokens, cookies, or unlock codes.
  • Prefer OAuth over URL tokens.
  • Set LOCALBRIDGE_DASHBOARD_TOKEN before using /app.
  • Review shell deny rules before enabling shell access for broad workspaces.

See security model.

Alternatives

OAuth + fixed HTTPS tunnel is the default because it fits ChatGPT Custom Connectors well. Other options exist:

  • OpenAI Secure MCP Tunnel, when available to your workspace
  • Cloudflare Tunnel
  • VPS reverse proxy
  • Static bearer token for private clients
  • Loopback-only no-auth testing

See alternatives.

GitHub Pages

The static product site lives in docs/. The repository includes a GitHub Actions workflow that deploys it to GitHub Pages after pushing to main.

Development

npm install
npm run typecheck
npm test
npm pack --dry-run

Render README and docs assets:

npm run docs:assets
npm run docs:preview

Public Release Checklist

  • [ ] Enable GitHub Pages with the included workflow.
  • [ ] Confirm npm test passes in GitHub Actions.
  • [ ] Keep .env.local and bridge.policy.json untracked.
  • [ ] Verify the ChatGPT connector uses OAuth and the correct /mcp URL.

License

MIT

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured