IntermediatePython

claude-code-localRun Claude Code Locally on Apple Silicon

claude-code-local is an open-source GitHub project enabling local, Anthropic API-compatible inference for Claude Code on Apple Silicon using MLX. This allows offline operation and keeps sensitive data on-device, ideal for scenarios involving NDAs, legal, or medical information where data privacy is paramount.

3.1K Stars
591 forks
2 issues
63 browse
Python
MIT
Indexed

Project Overview

claude-code-local is an open-source GitHub project enabling local, Anthropic API-compatible inference for Claude Code on Apple Silicon using MLX. This allows offline operation and keeps sensitive data on-device, ideal for scenarios involving NDAs, legal, or medical information where data privacy is paramount.

Bringing a powerful coding agent like Claude Code to run entirely on your local machine sounds like a dream for many, but few projects actually deliver. claude-code-local is one of those rare efforts, meticulously building an Anthropic API-compatible local service on Apple Silicon, powered by MLX, ensuring your Claude Code requests never leave your device.

The project's name pretty much spells out its mission. It functions as a local API endpoint, allowing Claude Code to make its usual requests, but instead of hitting a cloud server, the traffic is routed to a local model. The repository lists supported models including Qwen 3.5 122B, Llama 3.3 70B, and Gemma 4 31B. The project claims a reference speed of 65 tokens/second with Qwen 3.5 122B.

It's crucial to put that speed figure into context. Local inference performance is heavily dependent on your specific Apple Silicon chip, the amount of unified memory, and the quantization method used. That 65 tok/s is a benchmark from the project's specific setup, and your mileage will almost certainly vary. A more pressing concern for many will be memory: models of the 122B scale demand a significant amount of unified memory, making them impractical for entry-level Macs. Your ability to run these larger models hinges entirely on your machine's memory capacity.

For those genuinely facing compliance pressures, the ability to keep data on-device often outweighs raw generation speed.

Why Bother with Local AI?

Entrusting your code to cloud-based AI has become commonplace, but for certain teams, this isn't a matter of preference; it's a hard red line. Projects under strict NDAs, processing sensitive medical data, or analyzing legal documents — in these scenarios, merely knowing which server your prompts traverse can introduce significant compliance risks.

This is precisely where claude-code-local shines: data never leaves your device. The project description explicitly states it's 'offline' and 'airgap-ready,' meaning it's not just about minimizing data transfer, but designed to allow full workflows even in disconnected environments. The trade-off in speed for this feature is a worthwhile exchange, enabling the secure use of Claude Code in highly sensitive contexts.

API Compatibility: The Real Game Changer

Running a coding agent locally isn't just about getting it to execute; it's about seamless integration. claude-code-local tackles this by reimplementing the Anthropic API locally, essentially providing Claude Code with a local exit point. This means you don't need to alter your existing workflows or switch tools; you're simply swapping the cloud backend for your own machine.

Of course, there are clear trade-offs. Local models typically don't match the capabilities of their larger cloud counterparts, inference speed is capped by your hardware, and this entire solution is currently exclusive to Apple Silicon. Looking at the repository, the project has garnered around 3.1k stars and over 600 forks. It's implemented in Python, leverages MLX natively, and appears to be in its relatively early stages of development.

Who Should Pay Attention?

  • Developers working in legal firms, hospitals, or under strict NDA environments where code cannot leave the internal network.
  • Claude Code users with high-memory Apple Silicon machines who want to reduce their reliance on cloud APIs.
  • Developers interested in MLX inference and local model orchestration; this repository offers an excellent reference implementation.

Considerations Before Diving In

First and foremost, confirm your hardware. Apple Silicon is a strict requirement, and your unified memory capacity directly dictates the size of the model you can run. Don't expect a low-spec machine to handle a 122B model.

Secondly, always refer to the project's README. The list of supported models and Claude Code versions can change, so check the current documentation before you start, rather than relying on outdated guides.

Finally, be prepared for a different user experience. Local inference typically introduces noticeable latency compared to cloud APIs. For compliance-driven scenarios, this is a fair trade; however, if your primary motivation is just cost savings, you might find the performance disappointing.

claude-code-local, in its current form, feels like a promising early solution pointing in the right direction. Its most significant contribution is proving that tools like Claude Code can indeed operate independently of the cloud — a crucial capability for data-sensitive environments. As Apple Silicon Macs with larger memory become more common and local models continue to evolve, projects like this will become increasingly difficult to overlook.

open-source AIApple SiliconMLX inferencelocal LLMClaude Codeoffline AI programmingdata privacysensitive datalocal inference serviceNDA compliance

Project Rating

0.0 (0 Evaluation)

Share

Frequently Asked Questions

What is claude-code-local: Run Claude Code Locally on Apple Silicon?

claude-code-local is an open-source GitHub project enabling local, Anthropic API-compatible inference for Claude Code on Apple Silicon using MLX. This allows offline operation and keeps sensitive data on-device, ideal for scenarios involving NDAs, legal, or medical information where data privacy is paramount.

What language is claude-code-local: Run Claude Code Locally on Apple Silicon written in?

claude-code-local: Run Claude Code Locally on Apple Silicon is primarily written in Python.

What license is claude-code-local: Run Claude Code Locally on Apple Silicon under?

claude-code-local: Run Claude Code Locally on Apple Silicon is released under the MIT license.

Related Projects

No results yet

Explore More

Similar Tools

Cursor

Cursor

A smart code editor based on secondary development of VS Code, with "native built-in AI" as its core selling point. It does not rely on plugins but deeply integrates AI into the underlying architecture of the editor, enabling it to understand the context of the entire project's codebase. It also supports seamless migration of all VS Code configurations and plugins.

Google Antigravity

Google Antigravity

Antigravity supports multiple models, including Gemini 3 Pro, Claude Sonnet 4.5, and GPT-OSS, allowing developers to select the most suitable model for their tasks within the same environment.

Codex

Codex

OpenAI Codex is an AI programming model and assistant developed by OpenAI, capable of translating natural language instructions into corresponding source code. It provides developers with intelligent code completion and code generation functionalities. Initially launched in 2021 as the code model for the OpenAI API, it once served as the core engine for GitHub Copilot. With the evolution of OpenAI's technology, Codex returned in 2025 in a new form as an "AI programming agent," capable of understanding complex requirements and automatically writing and debugging code, significantly enhancing development efficiency and software delivery speed.

Kiro

Kiro

Kiro is an AI-powered programming IDE launched by AWS, which adopts a specification-driven development model. It transforms natural language requirements into clear specification documents and tasks, then uses built-in AI agents to generate code, debug, and optimize, providing comprehensive assistance throughout the development process of large-scale projects.

Trae

Trae

Trae (official website: trae.ai) is an AI-native integrated development environment (IDE) launched by ByteDance. It is not merely a programming assistant but rather a "collaborative partner" that deeply integrates large language models (LLMs) to help developers achieve more intelligent and automated software development—from requirements analysis and code construction to debugging and deployment.

Claude

Claude

Claude is an intelligent language interaction platform developed by the American AI company Anthropic. It integrates capabilities such as deep text understanding, information organization, code assistance, and task analysis, enabling it to handle more complex tasks beyond simple chat conversations. These include long-text summarization, image analysis, logical reasoning, and programming assistance, among others. Compared to some single-purpose Q&A bots, Claude functions more like an intelligent tool equipped with reasoning logic and scalable features.

Comments

Comments

0
0/500 Characters

No comments yet

Be the first to comment

Open Source Project

Explore, learn and contribute to open source AI projects to advance the development of artificial intelligence technology

View All