Set up Claude Code on your computer
The problem
You want to use Claude Code, Anthropic's agentic coding assistant that can read, write, and execute code on your behalf. You have a Mac, Windows, or Linux computer and are comfortable using a terminal. You want Claude to help with tasks like automating reports, cleaning data, or building simple tools.
The solution
Install Claude Code via npm (Node.js package manager), authenticate with your Anthropic API key, and start using it from your terminal. Claude Code can read your files, write code, run commands, and iterate on solutions. It works in any project folder and remembers context through CLAUDE.md files.
What you get
Claude Code running in your terminal, ready to help with coding and automation tasks. You can start conversations with 'claude' and it will read your files, suggest changes, and execute code with your permission. You'll have a CLAUDE.md file that gives Claude context about your organisation.
Before you start
- A modern computer: Mac (macOS 12+), Windows 10/11, or Linux
- Comfort using a terminal/command line
- Node.js version 18 or later installed
- An Anthropic account with API access (console.anthropic.com)
- Credit added to your Anthropic account
When to use this
- You're comfortable with terminal/command line interfaces
- You want Claude to help write, edit, and run code
- You have coding projects or automation tasks to work on
- You want an AI that can see your codebase and make changes directly
- You understand the basics of software development
When not to use this
- You're not comfortable using a terminal
- You just want to chat with Claude (use Claude.ai or Claude Desktop instead)
- Your IT policy doesn't allow installing npm packages
- You're working with highly sensitive data that shouldn't be sent to AI APIs - under UK GDPR, sending personal data to external AI services requires appropriate safeguards, a lawful basis, and privacy notice coverage
- You want a visual/GUI interface (consider Claude Desktop for simpler chat)
Steps
- 1
Check prerequisites
Make sure you have Node.js 18+ installed. Open a terminal and type 'node --version'. If you see v18 or higher, you're set. If not, download Node.js from nodejs.org and install it. You'll also need basic familiarity with terminal commands like cd, ls, and running scripts.
- 2
Sign up for Claude for Nonprofits (optional)
Check if your charity qualifies for discounted API pricing at anthropic.com/nonprofits. UK registered charities may be eligible. This isn't required but can significantly reduce costs for regular use.
- 3
Get your Anthropic API key
Go to console.anthropic.com, sign up or log in, and navigate to API Keys. Create a new key and copy it somewhere safe. Add credit to your account - £20-50 is reasonable for getting started and experimenting.
- 4
Install Claude Code globally
Open your terminal and run: npm install -g @anthropic-ai/claude-code. This installs Claude Code so you can use it from any folder. On Mac/Linux, you may need to prefix with 'sudo' if you get permission errors.
- 5
Authenticate with your API key
Run 'claude' in your terminal. The first time, it will ask for your API key. Paste the key you copied earlier. Claude Code stores this securely so you don't need to enter it again.
- 6
Test with a simple task
Navigate to a project folder (or create a new one) and run 'claude'. Try asking: 'What files are in this directory?' or 'Create a simple Python script that prints hello world'. Claude will show you what it plans to do and ask permission before making changes.
- 7
Create a CLAUDE.md file for your organisation
Ask Claude: 'Create a CLAUDE.md file that describes my charity's context. Interview me to gather the relevant information.' CLAUDE.md files help Claude understand your organisation, coding conventions, and preferences. Keep this file in your project root.
- 8
Understand the permission model
Claude Code asks permission before reading sensitive files, writing changes, or running commands. Pay attention to these prompts - you can approve, reject, or modify what Claude does. This keeps you in control and prevents accidents.
- 9
Learn key commands
Useful commands: /help for available commands, /cost to check your API usage, /clear to reset conversation context, Ctrl+C to stop a running operation. Claude Code remembers context within a session but starts fresh each time you run it.
Tools
Resources
At a glance
- Time to implement
- hours
- Setup cost
- free
- Ongoing cost
- medium
- Cost trend
- decreasing
- Organisation size
- small, medium, large
- Target audience
- it-technical, data-analyst
Claude Code uses API credits. Costs vary by usage - light use might be £10-30/month, heavy use could be £50-100+. Claude for Nonprofits offers discounts for qualifying charities.