The error likely happens if you do the following: To fix the error in your AWS CLI, run the command using the argument like so: Make sure to use an existing AWS profile. Your profiles can be found in the file. If you need guidance on setting up AWS SSO correctly on your local machine and use it with the AWS CLI effectively then I would recommend you to read this guide I wrote.