How to Set Up Claude Code for Your Team
A practical step-by-step guide to configuring Claude Code for team use -- covering CLAUDE.md conventions, MCP servers, worktree isolation, permissions, and best practices for multi-developer AI coding.
Your Team Needs More Than a CLI Install
Claude Code is individually powerful. One developer, one terminal, one codebase. But when a team of five or ten developers all run Claude Code on the same repository, things get complicated fast. Agents overwrite each other’s work. New team members get inconsistent results because they prompt differently. Nobody agrees on what the agent should or should not do without asking first.
The difference between one developer using Claude Code and a team using it well comes down to setup. Shared conventions, shared tooling, shared guardrails. This guide walks through the steps to get your team from “everyone has Claude Code installed” to “everyone gets consistent, high-quality results.”
Prerequisites
Before you start configuring team-level setup, every developer needs the basics in place.
Claude Code CLI installed. Follow Anthropic’s install guide. Verify it works by running claude in your project directory.
API key configured. Each developer needs an Anthropic API key, or your organization needs a centralized key with usage tracking. If you are on an Anthropic organization plan, set up the key at the org level so you get consolidated billing and usage visibility.
Git repository access. Claude Code operates on your codebase through git. Every team member needs clone access to the shared repo with permission to create branches.
Step 1: Configure CLAUDE.md for Team Conventions
CLAUDE.md is the most important file for team-level Claude Code usage. It sits at the root of your repository and tells every Claude Code session how to behave. Every developer on your team, and every agent session they start, reads this file automatically.
Think of CLAUDE.md as onboarding documentation that the agent actually reads. Put in it everything you would tell a new developer on their first day.
Coding standards. Specify your language, framework conventions, and formatting rules. If you use TypeScript with strict mode, say so. If you use camelCase for variables and PascalCase for components, say so. The agent follows what you write.
## Coding Standards
- TypeScript strict mode, no `any` types
- camelCase for variables and functions, PascalCase for React components
- Use named exports, not default exports
- All async functions must handle errors explicitly -- no silent catches
Architecture decisions. Document the patterns the agent should follow. Where do new API routes go. How is state managed. What is the testing strategy. Without this, the agent makes reasonable but inconsistent choices across sessions.
## Architecture
- API routes go in `src/api/routes/` with one file per resource
- State management uses Jotai atoms, never React Context for dynamic state
- All database queries go through the repository layer, never direct SQL in routes
What not to do. Negative instructions are as valuable as positive ones. If your team has learned the hard way that certain patterns cause problems, encode that knowledge.
## Anti-patterns
- Never use dynamic imports in the main process
- Never store secrets in localStorage
- Do not modify the database schema without a migration file
CLAUDE.md is a living document. Update it as your team learns what the agent gets wrong. Every fix you encode here prevents the same mistake across every developer’s sessions.
Step 2: Set Up MCP Servers for Your Team’s Tools
MCP (Model Context Protocol) servers give Claude Code access to tools beyond the file system. Out of the box, the agent can read and write files and run bash commands. MCP servers extend that to your team’s specific infrastructure.
Database access. If your team works with a database, an MCP server can let the agent query it safely — read-only, with parameterized queries — instead of writing raw SQL scripts that might hit production.
Internal APIs. If your team has internal services, dashboards, or documentation systems, MCP servers can expose those to the agent. The agent can look up API schemas, check service health, or pull context from your internal docs.
Project management tools. Connect your issue tracker so the agent can read ticket details, update status, or link sessions to specific tasks.
The key principle: give the agent read access broadly, write access narrowly. Let it query your database but not mutate it. Let it read tickets but not close them without a human in the loop.
MCP server configuration goes in .mcp.json at the project root so every developer gets the same tool access:
{
"mcpServers": {
"database": {
"command": "npx",
"args": ["your-db-mcp-server", "--read-only"]
}
}
}
Step 3: Establish Shared Workflows
Individual Claude Code usage is freeform — type a prompt, get a result. Team usage needs structure.
Use git worktrees for isolation. When two developers run Claude Code sessions on the same branch, they will create merge conflicts. Worktrees give each session its own working directory and branch. The agent works in isolation, and changes merge through your normal PR process. Some tools like Nimbalyst automate worktree creation and management, but you can set this up manually with git worktree add.
Adopt session naming conventions. When your team runs dozens of agent sessions per day, “Chat 1” and “Chat 2” tell you nothing. Establish a naming convention: feature/auth-jwt-migration, fix/cart-total-rounding, refactor/api-error-handling. This makes it possible to find and review specific sessions later.
Define your review process. Agent-generated code needs the same review rigor as human-written code. Decide as a team: do agent PRs get the same review as human PRs, or do they get extra scrutiny. In practice, most teams start with extra scrutiny and relax as they build trust in their CLAUDE.md configuration.
Write specs before prompting. For more on this workflow, see our guide to planning features with AI agents. The highest-leverage team habit is writing a short spec before starting a Claude Code session. Two paragraphs covering what you want built, any constraints, and how to verify it works. This is not overhead — it replaces the time you would spend iterating on vague prompts.
Step 4: Define Permissions and Guardrails
Claude Code has a permissions system that controls what the agent can do without asking. On a team, you want these configured consistently.
Default to ask. For destructive operations — deleting files, running database migrations, pushing to remote branches — configure the agent to ask before executing. Individual developers can relax permissions for their own sessions, but the team default should be cautious.
Restrict file patterns. If certain files should never be modified by the agent (CI configs, deployment manifests, security policies), specify those restrictions in CLAUDE.md.
## Agent Guardrails
- Never modify files in `.github/workflows/` without explicit approval
- Never modify `package.json` dependencies without explaining why
- Always run tests after making changes -- do not skip this step
Lock down production-adjacent operations. If the agent can run bash commands, it can theoretically do anything the developer can do. Set boundaries around deployment commands, production database access, and infrastructure changes.
Best Practices for Multi-Developer AI Coding
Branch per session, always. Never let two agent sessions work on the same branch. This is the single most common source of team friction with Claude Code.
Keep CLAUDE.md under 2000 words. The agent reads the entire file for every session. If it grows into a novel, the important instructions get diluted. Be concise. Link to detailed docs rather than inlining everything.
Rotate CLAUDE.md ownership. Assign someone on the team to review and update CLAUDE.md monthly. As the codebase evolves, the instructions need to evolve with it. Stale instructions are worse than no instructions.
Share prompts that work. Following best practices for coding with agents as a team makes a huge difference. When a developer finds a prompt pattern that produces great results, share it with the team. Build a library of effective prompts for common tasks: “write integration tests for a new API endpoint,” “refactor a module to use dependency injection,” “add error handling to all database calls in a directory.”
Track agent usage. Know how many sessions your team runs, what tasks they use the agent for, and where the agent produces results that need heavy editing. This data tells you where to improve your CLAUDE.md and where to invest in better MCP tooling.
Common Pitfalls and How to Avoid Them
Pitfall: Everyone writes their own CLAUDE.md. Claude Code supports personal instruction files, but team conventions belong in the repo-level CLAUDE.md. If each developer configures the agent differently, you get inconsistent code quality and style across the codebase.
Pitfall: No review process for agent code. Agent-generated code ships with the same bugs and design flaws as human code, just faster. Without code review, those flaws accumulate. Treat agent PRs as real PRs.
Pitfall: Overloading the agent with context. More context is not always better. A 5000-word CLAUDE.md with every edge case documented makes the agent slower and less likely to follow the important instructions. Prioritize the rules that prevent the most common mistakes.
Pitfall: Skipping the spec. When developers jump straight to prompting without writing a brief spec, they spend more time iterating on agent output than they save. Two minutes of spec writing saves twenty minutes of back-and-forth.
Pitfall: Running sessions on the same branch. This bears repeating. Two agent sessions on the same branch will create conflicts. Use worktrees or separate branches, every time.
Tools That Help: Adding a Visual Management Layer
The steps above work with Claude Code in the terminal. But as your team scales, managing all of this through terminal sessions and text files creates its own friction.
Nimbalyst adds a visual layer on top of Claude Code that makes team workflows easier to manage. A session kanban board shows every running agent session across your team, what each one is working on, and its current status. Visual diff review lets you review agent changes with side-by-side file comparison instead of scrolling through terminal output. Shared workspaces give the team a common view of project state, planning docs, and agent activity.
The agent underneath is still Claude Code. The configuration is still CLAUDE.md and MCP servers. What changes is visibility — you can see what every agent session is doing, review changes visually, and keep the team coordinated without switching between terminal tabs and chat windows.
For teams that are serious about using Claude Code as a core part of their developer workflow, that visibility layer is the difference between productive and chaotic.