How Do I Clear The Credentials In AWS Configure?

The rm ~/.aws/credentials command is a powerful tool for managing AWS credentials securely and maintaining a clean AWS CLI configuration. By following best practices and periodically cleaning up unused or outdated credentials, you can enhance the security and efficiency of your AWS environment

If you receive the following error message:


  1. Run the following command to remove the credentials file: rm ~/.aws/credentials
  2. Now run the following command to view users: aws iam list-users –output json

Make sure to add the output format to the command. Above, we requested .JSON format

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top