Name Identifier
A Name Identifier (NameID) is the piece of a SAML login message that identifies which user the message is about. When one system logs a user in and vouches for them to another system, the NameID is the value that tells the receiving system who that user is. It can take different forms, such as an email address or a scrambled identifier that reveals no personal details.
In SAML 2.0, the NameID is the element (typically carried within the <Subject> of an assertion) that identifies the authenticated subject to the relying party. Its NameID Format determines the structure and semantics of the value, common formats include email address, persistent, and transient identifiers, and the format and value are generally determined by the Identity Provider's configuration. Best practice in many deployments is for the NameID to be non-volatile and opaque so it uniquely and stably identifies the subject without exposing personal information; the appropriate format depends on the SP's requirements and the IdP's release policy. Note that the NameID is an identifier asserted as part of the authentication result and is distinct from authorization decisions and from any additional SAML attributes released alongside it.
Why it matters
The NameID is the anchor that ties a federated login to a specific user account at the relying party. In a SAML 2.0 SSO flow, the receiving service provider (SP) uses the NameID from the assertion to determine which local account the authenticated session belongs to. If the NameID value or its format changes unexpectedly, for example, when an Identity Provider is reconfigured to release a different format, the SP may fail to match the returning user to their existing account, resulting in failed logins or, worse, the creation of duplicate or mismatched accounts. Because of this, the stability and format of the NameID are operationally significant decisions, not incidental configuration details.
Who it's relevant to
Inside NameID
Common questions
Answers to the questions practitioners most commonly ask about NameID.
