Visual Studio Code 1.122, released in late May 2026, severs the last mandatory tether to a GitHub account for its AI features. For the first time, developers can plug in their own large language model keys and run chat, inline completions, and even Model Context Protocol servers without ever signing into a cloud identity service. The update targets developers inside air‑gapped networks, privacy‑sensitive enterprises, and anyone who simply prefers to keep their toolchain offline.
Shipyards, defense contractors, and financial institutions have long demanded AI‑assisted coding that doesn’t phone home. By enabling bring‑your‑own‑key (BYOK) models across the editor’s core AI surfaces, VS Code now delivers a local‑first Copilot alternative that respects network boundaries and data sovereignty.
The change lands in the stable channel after an extended Insiders preview, with Microsoft’s engineering team citing “overwhelming demand from regulated industries and open‑source communities.” While GitHub Copilot remains a paid subscription that requires authentication, the new BYOK path works with no account at all.
BYOK AI: How It Works
At its core, BYOK allows VS Code to send prompts directly to a model endpoint using an API key you supply. The editor stores the key in its local state—encrypted when possible—and never relays it to Microsoft or GitHub. The feature supports both cloud‑hosted models (OpenAI, Anthropic, Azure OpenAI, Google Gemini, local inference servers like Ollama or LM Studio, and any OpenAI‑compatible endpoint) and fully local models running on the same machine.
Setting up a BYOK model takes three steps:
- Open Settings and navigate to Chat: Model Provider.
- Choose Bring Your Own Key from the dropdown, which unlocks the Chat: Model API Key field.
- Paste your key, specify an endpoint URL if needed, and select the model ID from a list that VS Code auto‑discovers or manually enter one.
Once configured, the Chat view, inline code completions, and MCP servers all respect the selected model. The workflow mirrors the familiar Copilot Chat experience: highlight code, press Ctrl+I or click the sparkle icon, and your local or custom model generates a response.
MCP Servers Without the Cloud
Perhaps the largest leap in VS Code 1.122 is full BYOK integration with Model Context Protocol servers. MCP servers let developers extend AI capabilities with custom tools—database querying, internal API calls, file‑system operations—and previously required a GitHub‑linked Copilot session. Now, any BYOK‑powered chat session can invoke MCP tools, unlocking complex multi‑step reasoning tasks entirely on‑premises.
A developer can, for example, configure a local MCP server that reads proprietary sensor data, feed it natural‑language questions through VS Code’s chat panel, and have answers drafted directly into the editor—all without traffic leaving the corporate LAN. This architectural shift turns VS Code from a thin client into a self‑contained AI workstation.
The End of Mandatory GitHub Sign‑In
Since the introduction of GitHub Copilot in 2021, using AI in VS Code meant linking a GitHub account. Version 1.122 removes that requirement for BYOK models. Opening the Chat panel with a BYOK provider selected no longer presents a sign‑in prompt. Instead, the editor immediately connects to the configured endpoint.
This decoupling has three practical implications:
- True offline development: Developers on airplanes, submarines, or remote field sites can download a model locally and use AI completions without any internet connection.
- Compliance simplicity: Security teams no longer need to evaluate GitHub’s authentication pipeline or data‑handling policies; the editor’s telemetry can also be disabled, leaving zero external network calls during AI usage.
- Cross‑team collaboration: Open‑source projects can standardize on a freely available local model and share a VS Code workspace file with pre‑configured BYOK settings, removing friction for new contributors.
Microsoft’s own documentation notes that while GitHub Copilot still delivers a polished chat experience with access to Bing search and workspace indexing, BYOK is the recommended path for regulated environments where even encrypted outbound traffic is prohibited.
Security and Privacy Model
When a BYOK key is entered, VS Code encrypts it using platform‑native APIs—Data Protection API on Windows, Keychain on macOS, and a combination of libsecret and file‑system permissions on Linux. The key is never written to settings.json in plaintext; instead, a reference token is stored. The editor’s diagnostics reports confirm no key material appears in logs or network traces.
Data sent to the model endpoint flows directly from the local machine. Microsoft’s infrastructure is not in the request path. For cloud‑hosted models, this means your prompts and code snippets travel only to the selected provider’s API servers over TLS 1.3. For local models, everything stays on the machine. The responsibility for data handling thus shifts to the API provider’s privacy policy, not Microsoft’s.
Enterprise administrators can control BYOK availability through group policy. An updated configureBYOK policy, available in the May 2026 administrative templates, allows disabling BYOK entirely, whitelisting only specific endpoint domains, or forcing a particular model for all users. This granularity lets financial compliance officers, for example, mandate that only an on‑premises Azure OpenAI endpoint be used.
Supported Models and Providers
VS Code 1.122 ships with a flexible provider abstraction that any OpenAI‑compatible service can plug into. During the setup flow, the editor probes the endpoint’s /v1/models route to fetch the available model list, which appears in a dropdown. For developers who want maximum control, a manual entry field accepts any model identifier.
Out‑of‑the‑box tested and documented providers include:
- OpenAI (GPT‑4o, GPT‑4.1, GPT‑4o‑mini)
- Anthropic (Claude 3.5 Sonnet, Claude Opus, via Anthropic’s Messages API)
- Google Gemini (Gemini 2.5 Pro, Flash)
- Azure OpenAI Service (custom deployments)
- Ollama (local models such as Llama 4, Mistral, Mixtral)
- LM Studio (local inference server with GPU acceleration)
- Groq, Fireworks, Together AI, and any other OpenAI‑compatible platform
Early community testing confirms that 8‑bit and 4‑bit quantized models running via Ollama provide acceptable chat latency even on mid‑range CPUs, making the BYOK path viable on developer laptops without dedicated GPUs. The editor’s streaming response rendering is tuned to handle the slightly higher first‑token latency of local models gracefully.
Community and Early Feedback
Reaction across forums and developer Twitter threads has been overwhelmingly positive. “Finally, I can use AI at the nuclear plant’s SCADA lab,” wrote one engineer on the VS Code subreddit. Another developer shared a walkthrough for pairing a Raspberry Pi running Ollama with VS Code on a laptop, achieving a completely disconnected AI‑assisted coding setup for under $200.
Some users have raised legitimate concerns about token costs. Because BYOK models bill directly to the developer’s API account, a single heavy chat session can rack up charges if not monitored. VS Code addresses this with a built‑in cost estimator that shows the estimated price of the current conversation, updated in real time. A configurable spending cap can pause completions and display a warning when the limit is reached.
Open‑source maintainers are already distributing VS Code workspace files that bundle a shared BYOK configuration and a recommended model. One popular Rust repository now includes a .vscode/settings.json snippet that directs new contributors to download a specific 7‑billion‑parameter GGUF model and set their Ollama endpoint, ensuring everyone starts with the same AI assistance level.
The Model Context Protocol community has also responded swiftly. Multiple MCP server templates now include a “VS Code BYOK” configuration section, showing how to link a local SQLite explorer, a PDF parser, or a Jira instance to the chat panel without touching the public internet. This self‑service ecosystem is expected to accelerate the adoption of MCP as a standard for tool‑calling from within the editor.
Comparison with GitHub Copilot
It’s worth clarifying where BYOK stands relative to the existing Copilot subscription. GitHub Copilot remains a first‑party service that offers fine‑tuned models, semantic workspace search, and access to the Copilot Chat’s “agent” mode that can edit files and run terminal commands on the user’s behalf. Copilot also now includes internet search via Bing when allowed.
BYOK models, by contrast, provide only the raw model’s response capabilities. They cannot edit multiple files simultaneously, perform codebase‑wide refactoring, or execute shell commands natively—those advanced behaviors rely on Copilot’s own orchestration layer. However, developers can approximate many agentic flows by pairing a BYOK model with an MCP server that defines tools for those same actions, effectively building a custom Copilot‑like agent inside the chat panel.
The licensing also differs. GitHub Copilot is a subscription ($10/month individual, $19/month business) that includes model access. BYOK shifts the cost to the developer’s own API bill, which can be cheaper for light users or more expensive for token‑heavy workflows. Teams that already have negotiated enterprise rates with cloud providers often find BYOK more economical at scale.
Real‑World Scenarios
Defense and Intelligence
A defense contractor developing radar‑signal processing software in a classified environment can now install VS Code 1.122, load a local Llama‑4‑based model tuned on signal processing textbooks, and get context‑aware code explanations without ever connecting to an outside network. All MCP tools, such as a custom disassembler or a waveform plotter, run entirely within the secure perimeter.
Education
Universities concerned about students’ code being sent to external servers can provision a shared LM Studio instance on a campus server. Students configure their BYOK settings once and receive AI tutoring in their programming assignments. The institution retains full control over the data, and no student needs a GitHub account to complete coursework.
Regulated Industries
A pharmaceutical company validating a Python script for clinical‑trial data processing must adhere to strict GDPR and HIPAA requirements. By pointing BYOK at an on‑premises Azure OpenAI deployment, the company’s developers get AI assistance while audit logs remain within the corporate datacenter. The group policy preventing use of public endpoints ensures accidental misconfiguration doesn’t cause a breach.
What’s Next
Microsoft’s roadmap for VS Code’s AI capabilities hints at further decoupling. Upcoming releases may add native support for local embedding models to power semantic search without any cloud service, and a “BYOK agent mode” that could rival Copilot’s file‑editing abilities. The VS Code team has also promised a plugin marketplace section dedicated to BYOK‑compatible models, letting model providers distribute optimized configuration profiles with a single click.
For developers operating in highly restricted or offline environments, VS Code 1.122 is the most significant release in years. The ability to bring your own key and model, combined with MCP server integration, transforms the editor from a window into a remote service into a self‑sufficient AI development platform. It’s a recognition that not every engineer’s desk has an open internet pipe—and that productivity shouldn’t depend on one.