Claude Code for Beginners: Set Up an AI Agent in Your Terminal
From install to your first real task – Claude Code explained in practice
This article is part of the AI Agents Guide – the curated learning path for AI agents.
I've already described in general how AI agents in the terminal change your workflow. Here it gets concrete: how to set up Claude Code as a beginner and run your first real task.
What Claude Code is
Claude Code is an AI agent for the terminal: it reads and writes files in your project, runs commands, searches code and works through entire tasks – not just a chat snippet. That's exactly the difference from a browser chat: it has hands in your project directory.
Installation
The prerequisite is Node.js. Then install globally:
npm install -g @anthropic-ai/claude-code
Then change into your project directory and start the agent:
cd ~/my-project
claude
First start and login
On first start Claude Code walks you through the login – either via your Anthropic account (subscription) or an API key. Important to understand: the agent works in the current directory. So always start it where your project lives – that's its workspace.
Your first task
Instead of asking for code, you give it a task in natural language – for example:
“Read the README and explain in three sentences what this project does.”
or more concretely:
“Add error handling to the
parse_configfunction and write a test for it.”
Claude Code proposes changes, shows you diffs and asks before critical actions. You stay in control – the agent does the typing.
What makes it special: tools and MCP
Claude Code gets its power from tools: read/write files, shell commands, web search. Beyond that it can be connected to your own systems via MCP – what an MCP server is, I explain in detail here. That way the same agent can also drive your server or – as in my case – a whole blog.
Claude Code runs locally but barely needs any resources – in my case on the same power-efficient mini PC that carries the whole homelab:
Ad · Affiliate link – if you buy through it, I may earn a commission. It doesn’t change the price for you.
What I left out
- CLAUDE.md – project-specific instructions the agent honors automatically; worth it once you work regularly.
- Your own MCP servers & subagents – the next level.
- Permissions/sandbox – fine-tuning what the agent may do without asking.
Conclusion & outlook
With two commands your first AI agent runs in the terminal – and the difference from a browser chat is immediately tangible on the first real task. If you want to run the agent permanently on a server and control it from anywhere, it continues here: Claude Code with Remote Control.
Ad · Affiliate link – if you buy through it, I may earn a commission. It doesn’t change the price for you.