SEPTEMBER 7, 2026

IAM User and AWS CLI… for now

IAM User | aws login | Temporary credentials

01

THE APPROACH

An IAM user—not Identity Center—with aws login

This setup is for an individual IAM user when IAM Identity Center is not part of the account yet. The user signs in through the AWS Management Console, then aws login opens a browser and exchanges that authenticated session for temporary local credentials. No IAM access key needs to be created or stored on the machine.

02

CREATE THE USER

Give the developer console access

  1. Open IAM → Users and choose Create user.
  2. Enter a descriptive user name and enable access to the AWS Management Console.
  3. Add the user to a group that grants only the AWS service permissions required for the work.
  4. Require a password reset when appropriate, then configure MFA for the user.

Do not create an access key for this workflow. The console password establishes the browser session; aws login supplies temporary credentials to the CLI.

03

AWS CLI

Start a named local session

Install AWS CLI version 2.32.0 or newer, then authenticate a named profile. The command opens the default browser, where the IAM user completes sign-in. The resulting session can remain valid for up to 12 hours.

$ Terminalshell
aws --version
aws login --profile local-dev

# Confirm which identity the CLI is using
aws sts get-caller-identity --profile local-dev

Use the same profile explicitly in commands, or set AWS_PROFILE=local-dev for the current shell.

04

CLOSE THE SESSION

Log out when the work is done

End the local session explicitly, especially on a shared machine. Logging out removes the active CLI session without changing the IAM user’s console password or permissions.

aws logout --profile local-dev
05

AWS DOCUMENTATION

Read the source material