Skip to content
| Marketplace
Sign in
Visual Studio>Tools>CodeGPT Chat and AI Agents
CodeGPT Chat and AI Agents

CodeGPT Chat and AI Agents

Preview

Code GPT

codegpt.co
|
31,668 installs
| (5) | Free
CodeGPT is your AI-powered coding copilot for Visual Studio. Chat with state-of-the-art models from OpenAI, Google, Anthropic, Mistral, and more — and create, use, and share your own AI Agents, right inside the IDE.
Download

🧠 CodeGPT VS Extension

CodeGPT VS Extension is a Visual Studio extension that integrates advanced AI (GPT) capabilities directly into the IDE. It enables developers to interact with language models to explain, refactor, document, and analyze source code—all from a custom tool window within Visual Studio. The extension manages its own environment, local servers, and configuration, providing a smooth and productive experience.


🚀 Features

  • CodeGPT Tool Window: Interactive WebView2-based interface for sending prompts and receiving AI responses.
  • Code Explanation and Refactoring: Commands to explain, refactor, document, and find issues in selected code.
  • Editor Integration: Responds to editor events such as selection changes, file opening/saving, and more.
  • Secure Configuration Management: Stores and encrypts user configurations and secrets.
  • Autonomous Local Server: Spins up and manages a Node.js/Next.js server to process AI requests.
  • Automatic Updates: Checks for and applies CodeGPT environment updates transparently.

🛠️ Tech Stack

  • C# (.NET Framework 4.7.2): Main extension logic and Visual Studio UI management.
  • WebView2: Web interface rendering within Visual Studio.
  • Node.js / Next.js: Local server for prompt processing and AI model communication.
  • CefSharp.Wpf and Newtonsoft.Json: Dependencies for UI and data handling.
  • Nancy: Framework for internal API route management.

📦 Installation

  1. Clone the repository:
    git clone https://github.com/JudiniLabs/codegpt-VS-extension.git
    cd codegpt-VS-extension
    
  2. Open the project in Visual Studio 2022 or higher.
  3. Restore NuGet dependencies (this happens automatically when opening the project).
  4. Build the solution in Debug or Release mode.
  5. Install the generated extension (.vsix) in your Visual Studio instance.

⚙️ Environment Variables

  • No manual environment variables are required for standard operation.

  • The extension manages its configuration in: Collapse C:\Users.visualstudio-codegpt

  • Files such as secret.json and globalState.json are generated automatically.

  • If you need to customize paths or ports, check the SettingsManager class and advanced configuration in the source code.


🧪 Development

Prerequisites:

  • Visual Studio 2022+
  • Node.js installed (the extension may attempt to install it if missing)

Set up the local environment:

  1. Build and install the extension in Visual Studio's experimental mode.
  2. Upon startup, the extension will automatically download and spin up the local server.

Debugging:

  • Use breakpoints in C# for extension logic.
  • The Node.js/Next.js server runs on port 54112 by default.

🧵 Architecture

  • C# Extension: Handles UI, commands, and editor events.
  • Node.js/Next.js Server: Processes prompts and responds to the UI.
  • Communication: Local HTTP and messaging between WebView2 and the extension.
  • Configuration Management: Uses Windows registry and encrypted local files.

☁️ Deployment

  • Production: Build in Release mode and distribute the .vsix file.
  • Server: No external deployment required; the Node.js server is managed locally.
  • Updates: The extension checks for and applies updates automatically.

👥 Contributing

  1. Fork the repository and create a branch for your feature or fix.
  2. Make your changes following the project conventions.
  3. Ensure the solution builds and passes tests.
  4. Submit a Pull Request clearly describing your contribution.

🙋 FAQ

  • Why isn't the local server starting?
    Verify that Node.js is installed and port 54112 is available.

  • Where are my configurations saved?
    In C:\Users\<User>\.visualstudio-codegpt and in the Windows registry.

  • How do I report a bug?
    Open an issue on GitHub with clear steps to reproduce the problem.


  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft