A developer’s Claude Code CLI reference (2025 guide)

Stevia Putri
Written by

Stevia Putri

Stanley Nicholas
Reviewed by

Stanley Nicholas

Last edited September 30, 2025

Expert Verified

Let’s be real, the way we code is changing. The old picture of a developer working in total isolation is fading, replaced by a workflow that’s way more collaborative. And a big part of that new team often includes AI. For those of us who basically live in the command line, this used to mean awkwardly switching over to a browser chat every time we needed help. Not anymore.

Anthropic’s Claude Code is a powerful coding assistant that plugs right into your terminal. It’s not just a chatbot that answers questions; it’s designed to be an active partner in your coding process, helping you think better and automating the tedious stuff that eats up your day.

This guide is your complete Claude Code CLI reference for getting things done in 2025. We’ll cover everything from the first setup and basic commands to more advanced workflows and pricing. By the time you’re done reading, you’ll know exactly how to get the most out of this tool.

What is Claude Code?

Simply put, Claude Code is a command-line interface (CLI) that gives you direct conversational access to Anthropic’s AI models from your terminal. Think of it as having a pair programmer you can talk to without ever taking your hands off the keyboard.

Its main job is to help you write, understand, and fix code faster. Based on what we’ve seen in the official docs and from people using it, here’s what it can do:

  • Build out features based on plain English descriptions.

  • Debug problems by looking at your code and making sense of error messages.

  • Get the lay of the land and answer questions about any codebase, even if you’ve never seen it before.

  • Automate repetitive tasks like fixing linting errors, sorting out merge conflicts, or even drafting release notes.

It’s built for developers who love the speed and power of the terminal and would rather not have another IDE or chat window open.

Getting started: Setup and configuration

Like any good assistant, Claude Code works best when you give it some context. Spending a few minutes on setup can save you hours down the road by helping the AI understand your project’s rules and quirks right from the start.

Installation and authentication

Getting started is surprisingly straightforward. Since Claude Code is an npm package, you can install it with a single command.

"`bash

Install Claude Code globally

npm install -g @anthropic-ai/claude-code

Start a session

claude

"`

The first time you run claude, it will pop open a browser window and ask you to log in. You’ll need an active Claude Pro or Max subscription to use the CLI. Alternatively, you can set it up with an API key if you prefer to pay as you go.

Key configuration files for project memory

The real power of Claude Code isn’t just the AI model; it’s how it learns the specifics of your project. This is handled by a couple of key configuration files.

CLAUDE.md is basically the "memory" for your project. It’s a simple Markdown file where you can jot down coding standards, architectural notes, common commands, or anything else you want Claude to remember. It works in a hierarchy, so you can have a general file in your home directory (~/.claude/CLAUDE.md), a project-specific one in your repo’s root (./CLAUDE.md), and even files for individual components in subdirectories.

settings.json handles the tool’s behavior, like which model to use. More importantly, it lets you manage tool permissions. You can use allowedTools and disallowedTools to pre-approve safe commands (like git status or npm install) and block anything potentially dangerous (like rm -rf). This makes for a much smoother experience, as you won’t have to give it the green light for every little file edit or command.

Here’s a quick example of a CLAUDE.md you might whip up for a new project:

"`markdown

Project Context for Finance Tracker App

Coding Standards

  • Use TypeScript for all new code.

  • Write tests for all new functions using Jest.

  • Follow existing ESLint configuration.

Key Commands

  • npm run test: Run the full test suite.

  • npm run lint: Check for linting errors.

Architecture

  • Frontend: Next.js with Zustand for state management.

  • Backend: Node.js with Express and Prisma.

"`

Core commands and interactive features

Think of this section as your cheat sheet. These are the essential commands and features you’ll be using day-to-day to work with Claude Code.

Essential CLI commands and flags

Most of your time will be spent inside an interactive session, but these flags are super helpful for launching Claude with the right context or for scripting.

Command / FlagDescriptionExample
claude "query"Starts an interactive session with an initial prompt.claude "explain this project"
claude -p "query"Runs a single query and prints the response without starting a session. Great for scripts.`cat logs.txt
claude -c or ---continueJumps back into your most recent conversation.claude -c
claude -r "" or ---resume ""Resumes a specific conversation using its session ID.claude -r "abc123"
---modelTells Claude which model to use for the session (e.g., sonnet or opus).claude ---model opus
---add-dirAdds extra directories for Claude to look at.claude ---add-dir ../backend
---output-formatSets the output format for print mode (text, json, stream-json).claude -p "query" ---output-format json

Mastering interactive sessions: Slash commands

Once you’re in a session, slash commands are your best friend for managing the conversation and your workflow.

  • /help: Shows you all the commands you can use, including any custom ones you’ve set up.

  • /init: Scans your current project and creates a starter CLAUDE.md file. It’s a fantastic way to get the project memory going.

  • /clear: Wipes the conversation history clean. This is really useful when you’re switching to a totally different task in the same project and don’t want to confuse the AI with old context.

  • /compact: Summarizes the current conversation, keeping the important bits while making room in the context window for bigger, more complex tasks.

  • /config: Opens up a menu where you can tweak settings like the model choice and tool permissions for your project.

Providing context on the fly

You can also point Claude to specific files or run quick commands without interrupting your flow.

  • Referencing files with @: The @ symbol is the fastest way to get Claude to focus on a specific part of your codebase. For example: > Review @./src/components/Button.tsx for accessibility issues.

  • Running shell commands with !: Sticking a ! in front of a command lets you run it in your shell directly from the Claude prompt. It’s perfect for running a quick test or listing files to double-check a path. For example: > !npm test

Advanced workflows and limitations

Once you have the basics down, you can start weaving Claude Code into more complex parts of your development process. But it’s also good to know its limits and when another tool might be a better fit.

Common development workflows

Here are a few ways developers are using the CLI to get work done faster:

  1. Test-Driven Development (TDD): The TDD cycle gets a major speed boost. You can ask Claude to write a failing test for a new feature, run it to see it fail, and then immediately ask it to write the code that makes the test pass.

  2. Rapid Debugging: Instead of spending an hour tracing an error, just copy and paste the error message into the CLI. Ask Claude to check out the codebase, figure out what went wrong, and suggest a fix.

  3. Codebase Onboarding: When you’re joining a new project, Claude can be your expert guide. You can ask high-level questions like "explain the folder structure" or "how does user authentication work here?" and get up to speed in minutes, not days.

Limitations: When is a coding agent not enough?

Claude Code is a fantastic pair programmer, but it lives inside a bubble: your codebase. It knows your code inside and out, but it’s completely in the dark about what’s happening in the rest of your company’s tools.

This leads to two big problems. First, it can’t get to important project knowledge that’s stored somewhere else. The product specs are in Google Docs, the design system is in Figma, sprint planning is in Jira, and customer bugs are logged in a helpdesk like Zendesk. Without that context, the AI only has part of the story, which holds it back from making bigger, more strategic decisions.

Second, developers are constantly getting pulled away by questions from non-technical colleagues. The support team needs to know how a new feature works. The marketing team wants to understand a technical detail for a blog post. A coding agent isn’t built to handle this. The answers aren’t in a .js file; they’re buried in a Confluence page or a long Slack thread. Every time a developer has to stop what they’re doing, dig up that answer, and reply, their focus gets completely derailed.

Automating knowledge workflows: Going beyond the CLI

So, what do you do when the answer isn’t in the code? That’s where a different kind of AI agent is needed. Just as Claude Code automates coding in your terminal, eesel AI automates finding and sharing knowledge across your entire company.

eesel AI tackles these problems by connecting to all the apps your business already uses, from Confluence and Google Docs to Slack and Zendesk, and pulling everything into one central place.

With the AI Internal Chat, you can launch a bot that lives right in Slack or Microsoft Teams. It works like a Claude for your company’s internal knowledge, letting anyone ask questions and get instant, accurate answers without ever having to ping a developer.

Best of all, you can set it up yourself. You can connect your knowledge sources and launch your first internal Q&A bot in just a few minutes.

Claude Code pricing

To use the Claude Code CLI, you’ll need a paid Claude.ai subscription. The free plan doesn’t give you terminal access. Here’s a quick look at the plans that do.

PlanPrice (Billed Monthly)Key Features Included
Free$0Basic chat on web/mobile. Does not include Claude Code CLI access.
Pro$20 / monthEverything in Free, plus more usage, and access to Claude Code in your terminal.
MaxFrom $100 / monthEverything in Pro, plus 5x or 20x more usage, early access to features, and priority access.
This ultimate guide for 2025 shows you how to master Claude Code from setup to advanced workflows.

Choosing the right AI agent

Claude Code is a fantastic tool that can seriously boost a developer’s productivity by handling coding tasks right where they work: the terminal. It’s a powerful and well-designed agent for anyone who wants to code faster and more effectively.

But at the end of the day, it’s about using the right tool for the job. For writing, debugging, and understanding code, a dedicated coding agent like Claude Code is the perfect fit. For managing your team’s shared knowledge and putting a stop to the constant interruptions, you need a specialized knowledge platform.

While Claude Code is streamlining your terminal, your team might still be digging for answers across a dozen different apps. You can stop the interruptions and give your whole company instant access to the information they need. Try eesel AI for free and build an internal Q&A bot in minutes.

Frequently asked questions

It’s a command-line interface that provides direct conversational access to Anthropic’s AI models from your terminal. Developers can use it to write, debug, understand code, and automate repetitive coding tasks faster.

You can install it globally via npm using npm install -g @anthropic-ai/claude-code. After installation, you’ll need an active Claude Pro or Max subscription for authentication.

Key commands include claude "query" for starting a session, claude -c to resume your last conversation, and slash commands like /init to generate a CLAUDE.md or /clear to reset context. You can also reference files with @ and run shell commands with !.

It uses CLAUDE.md files throughout your project directory to store coding standards, architectural notes, and other important context. Additionally, settings.json manages tool permissions and model choices.

While excellent for code, it only understands your codebase and lacks access to knowledge stored in other company tools like Google Docs, Jira, or Slack. It cannot address non-technical queries from other departments.

To use the CLI, you need an active Claude Pro ($20/month) or Claude Max (from $100/month) subscription. The free Claude.ai plan does not include CLI access.

Share this post

Stevia undefined

Article by

Stevia Putri

Stevia Putri is a marketing generalist at eesel AI, where she helps turn powerful AI tools into stories that resonate. She’s driven by curiosity, clarity, and the human side of technology.