Skip to content
IAM Policy Generator

IAM role

An IAM role is an identity in an AWS account with permissions but no long-term credentials of its own. A principal that assumes it receives temporary credentials. A role has two kinds of policy: a trust policy that says who may assume it and permission policies that say what it can do.

All terms ยท Open the workbench

An example, sourced

AWS says that when you are building on a compute service such as EC2 or Lambda, AWS delivers the temporary credentials of an IAM role to that compute resource, so there is no need to distribute long-lived credentials for an IAM user to your workloads.

Why it matters here

AWS recommends roles over long-term access keys for humans and workloads. The workbench builds the trust and permission halves separately.

Sources

  1. https://docs.aws.amazon.com/IAM/latest/UserGuide/best-practices.html, read 16 Nov 2026

Last reviewed 16 Nov 2026.