Even if you are using the Claude Code, which is a complete external terminal for the VS code, then it is just half of what the tool can perform. There is a quite simple way to use the Claude code VS code extension which you can easily perform by using some simple steps.
Before you get started with installing the Claude code VS code extension, make sure you have:
- An Anthropic account
- API access to Claude (request or obtain credentials)
- Basic programming knowledge
Here are the simple steps for you to follow to use the Claude code VS code extension in a very simple and quick way to use it as a ChatGPT alternative.
How to Use Claude code in VS code
After using the Claude code VS code extension, you can use two or more terminals parallelly and get answers for both by just switching the window on your screen. And to install the Claude code VS code extension, here are the steps you can follow on your own without any professional interference.
Step 1: Install the Claude code
To install the Claude code VS code extension instead of any AI code editor, go to any terminal in your system and run the following code in it: ‘npm install -g @anthropic-ai/claude-code’
Then verify the completion of the installation by using the command in your system
‘Claude –version’
There you will find the string of the version, for example, 1. x. x. and if you do not find it anyway then make sure that the npm global bin is present in the PATH you are using for this command.
Also know: Best YouTube Video Summarizer with AI Technology
Step 2: Download the VS Code Extensions
Now you need to install the VS Code extension in your system after the Claude code VS code extension, and for that here are the following you can follow:
Step 1: Go to the VS Code to install the Claude code VS code extension.
Step 2: Press together the ‘Ctrl + Shift + X’ in your keyboard for Windows and press Cmd + Shift + X in your MacOS and this will open the Extension panel in VS Code.
Step 3: In that Extension panel in VS Code, search for the Claude Code to find the extension.
Step 4: Look for the extension and specifically published by Anthropic
Step 5: Click on it to install.
Or you can simply go to the VS code and open the (Ctrl + Cmd + P) and then paste the following command to install the Claude code VS code extension:
‘Ext installs anthropic. Claude-code’
Step 3: Go to the Project Folder
The Claude code only works with the workspace, not just like with any kind of lose files. In simpler words, it needs a workspace to function, so you need to make a folder in your system before you operate the code with your system.
You can simply go to the File and then open a folder, and this will open the project root for your next project.
Step 4: Open the Integrated Terminal in VS Code
Now open the integrated terminal for your projects in VS Code, for Windows, press (Ctrl + ‘) and for MacOS press (Cmd +’).
The project root of your project should be the current terminal directory, but not the by default directory that opens when you open the folder.
Also know: Best Artificial Intelligence App Development Tools
Step 5: Go to the Claude Code
Next, you need to start the Claude Code and make sure it is running and figure out that you can run the following command: “Claude”. It must detect whether the extension is running or not, and with this you can also make sure that the extension is completely installed or not. If the Claude code VS code is working and extension is installed completely, a message will pop up on your screen.
If the Claude code VS code is working or the auto detection is not working, then you can restart the VS code and use the following:
‘Claude –ide’
By this, you can simply use the Claude code in VS code and after you install these extensions, you do not need any other extension to use the Claude code VS code extension in the VS code to setup and run the Claude code.
Frequently Asked Questions (FAQs)
Q1. How to use Claude code in VS code?
Ans. You can use Claude code in VS code after installing the extension in the VS Code and for that following are the steps:
Step 1: Go to the standard terminal in the application:
Step 2: Run the code ‘npm install -g @anthropic-ai/claude-code’ in that terminal and install it globally.
Step 3: Then go to the Visual Studio Code. And press the ‘Ctrl + Shift + X’ on your keyboard for Windows and press Cmd + Shift + X on your MacOS and open Extensions.
Step 4: Look for the ‘Claude Code’ and install the official version using Anthropic.
Q2. What is the best way to provide the proper context in the Claude code?
Ans. To provide the proper context in the Claude code, you must give a proper name to the root folder of your project. And you must outline the specific tech stack for your project. And you can also use the (.claudeignore) files to block all the unwanted files that drain or create unwanted traffic within your limits.
Q3. Is the Claude Code extension free to use for everyone in VS Code?
Ans. Yes, the CLI version and all the VS Code extensions are free of cost to install and use. But if you use any background AI tool, then you need to pay for that.
These were the main and basic steps to install the Claude code VS code extension and use it to run the Claude code in VS Code extension. By using this, you can run two terminals in parallel that will help you increase your productivity, and you do not need to create different workspaces. After this, you can run the parallel terminals, and you can easily see the two results parallelly by just switching the windows.










