# CLAUDE_CODE_USE_BEDROCK

> Set to 1, it runs Claude Code on Amazon Bedrock.

**Field:** Artificial Intelligence  
**Category:** Claude Code  
**Also known as:** CLAUDE_CODE_USE_VERTEX, CLAUDE_CODE_USE_FOUNDRY, CLAUDE_CODE_USE_MANTLE, CLAUDE_CODE_USE_ANTHROPIC_AWS, CLAUDE_CODE_USE_ANTHROPIC_GOOGLE_CLOUD, CLAUDE_CODE_USE_* variables

## Think of it like

It is like you choose which shop to buy the same toy from.

## Definition

CLAUDE_CODE_USE_BEDROCK set to 1 sends Claude Code's requests to Amazon Bedrock. Each other cloud has its own: _VERTEX for Google, _FOUNDRY for Microsoft Foundry and _MANTLE for Mantle on Bedrock. That cloud then signs you in with its own keys. It also bills its own account. A cloud set this way is first in the sign-in order.

## Example

Jack's firm buys all its AI from AWS. He sets this to 1, and each request goes through the firm's Bedrock account.

## Example code

```bash
export CLAUDE_CODE_USE_BEDROCK=1
export AWS_REGION=us-east-1
claude
```

Run Claude Code on your Bedrock account.

## Why it matters

A firm can use Claude Code under the cloud deal and bills it has now.

## Common mistake

Setting two of them at once. Pick one cloud per session, so you know which one you are on.

## Three principles

- **One per cloud.** Bedrock, Google, Foundry.
- **Set to 1.** To turn it on.
- **First in line.** Beats API keys.

## Related terms

- [Amazon Bedrock](https://learn.benibix.com/term/ai/amazon-bedrock)
- [Microsoft Foundry](https://learn.benibix.com/term/ai/microsoft-foundry)
- [Gemini Enterprise Agent Platform](https://learn.benibix.com/term/ai/gemini-enterprise-agent-platform)
- [/setup-bedrock Command](https://learn.benibix.com/term/ai/setup-bedrock-command)
- [Claude Code Cloud Providers](https://learn.benibix.com/term/ai/claude-code-cloud-providers)

![One CLAUDE_CODE_USE_ variable picks the cloud. Each cloud then reads its own settings.](https://learn.benibix.com/diagrams/env-provider-switch.svg)

---

Source: https://learn.benibix.com/term/ai/claude-code-use-provider-variables
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-17
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
