Skip to content
masterclassBuddyTech Buzz5 fresh blogs · 5:00 AM IST

Kinde · Module

getUserProfile

getUserProfile asynchronously returns the profile of the currently logged-in user in Kinde’s React SDK. Obtain it from useKindeAuth and call it without arguments.

How it works

In the Kinde React SDK, obtain getUserProfile from useKindeAuth and await it to retrieve the currently logged-in user’s profile. The returned object exposes identity and contact fields such as the Kinde ID, names, email, and optional profile picture.

Syntax

const { getUserProfile } = useKindeAuth();
const profile = await getUserProfile();

Returns

A profile object for the currently logged-in user, including id, givenName, familyName, email, and an optional picture.

Key points

  • The helper resolves to the current authenticated user’s profile.
  • Access getUserProfile by destructuring it from the Kinde authentication hook.
  • Invoke the helper with no arguments and await its asynchronous result.
  • The profile exposes the user’s Kinde identifier as a string id field.
  • A picture URL can be present, but the profile picture is not guaranteed.

Common mistakes

  • Call the helper for the signed-in user; it is not a general user lookup.

Example: Load the current user profile

import { useKindeAuth } from '@kinde-oss/kinde-auth-react';

export default function Profile() {
  const { getUserProfile } = useKindeAuth();

  async function loadProfile() {
    const profile = await getUserProfile();
    console.log(profile);
  }

  return <button onClick={loadProfile}>Get profile</button>;
}

This component obtains the profile loader from the Kinde React hook and invokes it asynchronously when the button is clicked.

When to use it

Render identity details

Profile pages

Pre-fill user information

Account settings

Show the signed-in user

Authenticated dashboards

Interview questions

QHow do you call getUserProfile in the Kinde React SDK?

getUserProfile is obtained from useKindeAuth and called as an asynchronous function. Awaiting it returns the profile object for the currently logged-in user.

Follow-up: How would you display the result safely? Store the resolved value in component state and guard optional fields before rendering them.

QWhat information does the returned profile contain?

The profile includes the user’s Kinde ID, given name, family name, email, and picture when available. These values can be rendered from the resolved profile object.

Follow-up: Which profile field may be unavailable? The picture is optional, so the UI should tolerate its absence.

QHow should a React component integrate the helper?

Destructure getUserProfile from useKindeAuth, then invoke it from an event handler or another appropriate asynchronous flow. The documented usage awaits the result before logging it.

Follow-up: Why avoid calling it directly during every render? Repeated render-time calls can trigger unnecessary asynchronous work; use an event or controlled effect instead.

  • useKindeAuth
  • user
  • id
  • givenName
  • familyName
  • email
  • picture

Source: React SDK - Kinde docs. Checked 2026-10-15.