name
, picture
field and more. The picture field is populated by either the social provider profile picture or the Gravatar image associated with the user’s email address.
By default, all database users will have a placeholder image with their initials. When you authenticate the user, this picture field is referred to as user.picture
.
user.picture
attribute is not directly editable when provided by other than Auth0 such as Google, Facebook, or X. To edit this attribute, you must configure your connection sync with Auth0 so that user attributes will be updated from the identity provider only on user profile creation. To learn more, read Configure Identity Provider Connection for User Profile Updates. Root attributes will then be available to be edited individually or by bulk import using the . To learn more, read Bulk User Imports.
Alternatively, you can use metadata to store the picture attribute for users. For example, if your app provides a way to upload profile pictures, once the picture is uploaded, you can set the URL to the picture in the user.user_metadata.picture
:
user_metadata
is returned in the , we’ll need to create a new Action to check whether the event.user.user_metadata.picture
attribute is present, and if so, replace the user.picture
attribute with that value. This ensures that the picture from the user_metadata
is returned in the picture
claim of the ID Token.
Change user pictures
), select the Login / Post Login
trigger because you’ll be adding the Action to the Login flow, then select Create.
picture
property that may come from an external identity provider login, such as Google.