CloudConsole

aws configure

Updated 16 November 2026 · How we write and check guides

Short answer

aws configure prompts for an access key ID, secret access key, default Region and default output format, and saves them for the default profile (or the one named with --profile) in ~/.aws/credentials and ~/.aws/config. For people with IAM Identity Center, aws configure sso is the better choice, because it avoids long-term keys.

Terminal running $ aws configure --profile ci-deploy with its example output
A worked example from this page with its output. Copy commands from the text below, not from the image.

What the command does

Run without a subcommand, it is an interactive wizard. Pressing Enter keeps the current value, shown in brackets:

$ aws configure --profile ci-deploy
AWS Access Key ID [None]: AKIAIOSFODNN7EXAMPLE
AWS Secret Access Key [None]: wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
Default region name [None]: eu-west-2
Default output format [None]: json

The keys go to ~/.aws/credentials, the Region and output format to ~/.aws/config.

# ~/.aws/credentials
[ci-deploy]
aws_access_key_id = AKIAIOSFODNN7EXAMPLE
aws_secret_access_key = wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY

# ~/.aws/config
[profile ci-deploy]
region = eu-west-2
output = json

Subcommands

CommandUse
aws configure listShow the active profile's values and where each came from
aws configure get region --profile xRead one setting
aws configure set region eu-west-2 --profile xWrite one setting without prompts, ideal for scripts
aws configure list-profilesList profile names
aws configure ssoCreate an IAM Identity Center profile
aws configure import --csv file://credentials.csvImport keys from the console's CSV download
aws configure export-credentialsPrint a profile's credentials for other tools

Worked examples

Change only the default Region:

aws configure set region eu-west-2

Set up a role profile that assumes a role using your default credentials:

aws configure set role_arn arn:aws:iam::123456789012:role/Admin --profile admin
aws configure set source_profile default --profile admin
aws configure set mfa_serial arn:aws:iam::123456789012:mfa/alex --profile admin
aws sts get-caller-identity --profile admin

Check what is in effect when something behaves unexpectedly:

aws configure list --profile admin

Where settings come from

The CLI resolves each setting in a fixed order and stops at the first source that provides it: command-line options such as --region and --profile, then environment variables, then the credentials file, then the config file, and finally container or instance metadata when running on AWS. aws configure list shows the winning source for each value in its Type and Location columns, which is the fastest way to explain why a setting seems to be ignored.

Output formats

ValueGood for
jsonDefault; scripts and jq
textTab-separated; shell loops with --query
tableReading on screen
yaml / yaml-streamHuman-readable structured output (CLI v2)

Anything else, such as JSON with capitals or a stray space, produces Unknown output type.

Gotchas

Questions

What should I enter for default output format in aws configure?

json is the usual choice. text, table, yaml and yaml-stream are also valid; anything else causes an Unknown output type error.

How do I configure a named profile?

Run aws configure --profile <name>, or set individual values with aws configure set <key> <value> --profile <name>. Use it with --profile <name> or AWS_PROFILE.

Why is aws configure sso not working when aws configure is?

configure sso needs AWS CLI version 2, the IAM Identity Center start URL and the Region where Identity Center is set up. A wrong SSO Region is the most common mistake.

When this happens away from your desk

Setting up credentials is the first step, and the one people least want to repeat on a new device. CloudConsole is built as a phone app for AWS with production guardrails.

About the app → · Download on the App Store

Sources