AI & Agents

How to Connect Devin AI to VS Code

Connecting Devin AI to VSCode (Visual Studio Code) bridges local development environments with autonomous cloud engineering sessions. By configuring secure API access with the Devin Sessions extension, developers can run cloud agent tasks, inspect diffs, and sync settings inside their IDE. This guide details the complete authorization, local-to-cloud handoff, and workspace syncing procedures for devin ai vscode.

Fast.io Editorial Team 12 min read
Devin sessions can be managed directly from the Visual Studio Code sidebar.

Why Connect Visual Studio Code to Devin AI?

While Visual Studio Code is the choice of 75.9% of developers globally [Stack Overflow 2025], the emergence of autonomous coding agents like Devin AI has shifted the development approach from local text editing to cloud-based coordination. Developers no longer just edit code in isolation. They coordinate cloud-based AI processes that build, test, and deploy software. Connecting Devin AI to VS Code allows developers to manage autonomous sessions directly from their editor, bridging local workflows with cloud compute sandbox environments.

According to the integration guidelines, "The Devin VS Code integration uses the Devin Sessions extension to interact with autonomous cloud agent runs directly from Visual Studio Code." This setup allows developers to delegate tasks, monitor progress in real time, and review changes without switching back and forth between the web application and their IDE. The integration acts as a window into the remote virtual machine where Devin operates.

By integrating these tools, you can instruct the agent to write code, debug issues, or execute tests on a remote machine while you continue editing files locally. The agent runs inside a secure sandbox, executing commands and editing code as if it were a remote human collaborator. This collaborative model reduces context switching, increases efficiency, and ensures that the agent's work remains transparent and controllable at every stage.

Setup Steps: Installation and Secure API Authorization for Devin AI VSCode

Authorizing Visual Studio Code to manage your Devin AI sessions requires installing the official extension and setting up a secure API handshake. The integration requires Visual Studio Code v1.85.0 or later to function properly, as it relies on recent API additions for sidebar management and secret storage.

To begin the installation process, open the Extensions view in Visual Studio Code by using the keyboard shortcut Cmd+Shift+X on macOS or Ctrl+Shift+X on Windows and Linux. Search for "Devin Sessions" in the search box. Look for the official extension published by Cognition and click Install. You can also download the packaged VSIX file from the marketplace or the official Cognition repository and install it manually by selecting the Install from VSIX option in the Extensions menu.

Once the extension is installed, you must generate a secure API key to authorize the connection. Navigate to your Devin account settings at app.devin.ai/settings/api-keys. Click the option to create a new API key, give it a descriptive name, and copy the generated token. Keep this token secure, as it grants full access to trigger and control coding sessions on your Devin account.

Back in Visual Studio Code, open the Command Palette by pressing Cmd+Shift+P on macOS or Ctrl+Shift+P on Windows. Type the authorization command:

Devin: Set API Key

Select this command and paste the copied API key into the input box, then press Enter. The extension saves the API key using Visual Studio Code's built-in Secret Storage API, which maps to your operating system's native keychain, keeping it safe from local inspection.

To make session management easier, you should also set your user email to filter out other team members' sessions. Open the Command Palette again and run:

Devin: Set User Email

Input the email address associated with your Devin account. This configures the sidebar to only show your sessions by default, keeping your IDE interface organized.

Syncing Workspaces: How Devin Syncs Code State

A common misconception is that the Devin VS Code integration continuously and in real time synchronizes your local workspace directory with the cloud environment. In practice, Devin runs inside a completely isolated virtual machine sandbox in the cloud, complete with its own shell, web browser, and local databases. Syncing the state of your local workspace with these cloud sessions requires a specific set of Git practices and environment configurations.

Git serves as the primary source of truth for all code synchronization. When you trigger a session, Devin clones the repository branch from your remote host, such as GitHub. Devin performs its autonomous tasks in the cloud sandbox, commits the modifications to a new branch, and pushes the changes back to your repository, opening a Pull Request. To sync these changes to your local machine, you fetch the branch from your remote host or click the Checkout PR button in the extension sidebar, which pulls the branch directly into your local workspace.

If you require real-time, interactive access to the active files inside Devin's cloud sandbox, you can connect your local editor directly to the remote virtual machine. The extension includes a Remote SSH shortcut represented by a Visual Studio Code icon next to each active session. Clicking this icon establishes a Remote SSH connection from your local IDE to Devin's sandbox. Once connected, your local editor acts as a direct client for the remote file system, ensuring that any file modifications made by Devin or yourself are immediately visible and synchronized.

To make Devin's remote environment match your local coding setup, you can import your Visual Studio Code settings, extensions, and keybindings. When you start a new session, the Devin welcome screen provides an auto-import script that you can run in your local terminal to copy settings automatically. Alternatively, you can export your local profile to a code-profile file using the Preferences: Open Profiles option in your IDE, then run the command:

Preferences: Devin: Import Profile (Manual)

inside the Devin session to load your custom keybindings and settings.

For developers who prefer working locally, the Devin CLI offers a local-to-cloud bridge. You can run the CLI locally to grant Devin access to your local files. If the task grows too large for your local machine or requires cloud-exclusive tools, you can hand off the session to a cloud agent. Executing the command:

/handoff

packages your conversation context and the current git branch state, uploading them to create a cloud session that picks up exactly where you left off.

Fastio features

Manage Devin AI VSCode workspaces and persistent code states

Get a shared cloud workspace with built-in version history, automatic document indexing, and a secure Model Context Protocol server for your Devin AI VSCode sessions. Start your 14-day free trial on our Starter ($29/mo), Business ($99/mo), or Growth ($299/mo) plans today.

Guide to Operating Devin Sessions within the IDE

Once authorized, you can control Devin sessions directly from the Visual Studio Code interface. The extension adds a dedicated Devin tab to your activity bar, which you can pin to your sidebar for quick access. This tab contains the Your Devins panel, listing all active, queued, and archived sessions.

You can launch a new session at any time using keyboard shortcuts. Press Cmd+G on macOS or Ctrl+G on Windows to open a prompt input box at the top of the editor. If you select a block of code in your editor before pressing the shortcut, that code is automatically attached to the session prompt as file context. To add more files or text to your prompt before sending, use the keyboard shortcut Cmd+Shift+G on macOS or Ctrl+Shift+G on Windows.

As the agent runs, the extension updates the sidebar status in real time. You can monitor the session's progress or chat with the agent using the chat panel. For more detailed visualization, click the Globe icon next to the session name to open the full chat and browser view in your default web browser.

Reviewing Devin's changes before merging them into your main codebase is important. The extension provides two ways to inspect modifications:

Global Diff View: Clicking the global diff icon displays a combined view of all files modified during the session, allowing you to see the overall impact of the agent's work.

Read-Only File Diffs: Expanding the session item in the sidebar lists each file Devin edited. Double-clicking a file opens a read-only diff comparison in your editor.

If you encounter issues with the connection, try running the Devin: Set API Key command again to refresh your credentials. If Devin's files are not updating in the sidebar, verify that your local Git repository is connected and that the remote branch has been pushed. If the Remote SSH connection fails, verify that your local SSH client is configured correctly and that your network allows outgoing SSH connections on custom ports.

Managing Developer Workspaces and Agent Context in Fast.io

While Devin AI operates as an autonomous coding agent, software teams require a persistent workspace where human developers and AI agents can collaborate, share assets, and manage documentation. Standard cloud storage solutions like Amazon S3 or Google Drive are either too technical for document sharing or lack the metadata and search capabilities needed for agent workflows. Fast.io fills this gap by providing an intelligent, shared workspace where teams and agents coordinate.

Instead of relying on local sync daemons that cause conflict files, Fast.io streams files on demand from organization-owned workspaces. This cloud-native architecture ensures that both humans and agents access the exact same files without local I/O bottlenecks.

Fast.io provides several capabilities designed for agentic workflows:

Per-file Version History: Fast.io maintains a complete version history for every file. When multiple agents or humans edit files concurrently, you can inspect and restore prior versions, keeping the work history auditable.

Intelligence Mode: By enabling Intelligence Mode on a workspace, files are indexed automatically. This allows agents to run semantic search and ask questions with citation-backed responses, serving as a built-in RAG system.

Metadata Views: Differentiate from simple search, Metadata Views turn documents into a queryable database. You can define fields in plain English, and the AI designs a typed schema (such as Text, Integer, Decimal, Boolean, URL, JSON, Date & Time), matches files, and populates a spreadsheet. Agents can query and update these views programmatically. Read more about data extraction on the Metadata Views page.

MCP-Native Access: Fast.io exposes action-based Model Context Protocol tools via Streamable HTTP at /mcp and legacy SSE at /sse. Any agent that supports MCP can connect to search workspaces, upload files, and trigger workflows.

Ownership Transfer: An agent can set up a workspace, populate it with files, configure folders, and then transfer ownership to a human team member while maintaining necessary admin permissions.

Fast.io has no permanent free plan or free agent tier. The Starter plan is $29/month, the Business plan is $99/month, and the Growth plan is $299/month. You can start with a 14-day free trial, which requires a credit card. Developers can set up workspaces for clients for free, then hand them off to the client's administrator who enters billing details to start the trial, maintaining clear ownership and control.

Frequently Asked Questions

Is there a VS Code extension for Devin AI?

Yes, Cognition AI provides an official VS Code extension called Devin Sessions. It is available in the Visual Studio Marketplace and allows you to start, manage, and interact with autonomous Devin sessions directly from your IDE sidebar.

How do I add Devin AI to VS Code?

To add Devin AI to VS Code, install the Devin Sessions extension from the marketplace. Then generate an API key from app.devin.ai/settings/api-keys, open the VS Code Command Palette, select the Devin: Set API Key command, and paste your API key to authenticate the extension.

How do I generate a Devin API key?

Log in to your account at app.devin.ai, navigate to the settings page, and select API Keys. From there, click the button to generate a new API key, copy the token, and configure it within your local IDE settings using the Command Palette.

How does Devin sync workspace changes with my local computer?

Devin manages code synchronization through Git version control, pulling repository branches to its cloud sandbox and pushing changes back as Pull Requests. For real-time sync during active sessions, you can connect via VS Code Remote SSH to work directly on the remote sandbox.

Related Resources

Fastio features

Manage Devin AI VSCode workspaces and persistent code states

Get a shared cloud workspace with built-in version history, automatic document indexing, and a secure Model Context Protocol server for your Devin AI VSCode sessions. Start your 14-day free trial on our Starter ($29/mo), Business ($99/mo), or Growth ($299/mo) plans today.