this link to get name from a UserID
there's nothing about it. but im trying to get the name from a user id (without them being in game)
if there's something else. I couldnt find anything beside this.
It's not too hard to understand. This is a function of the players service, the wiki informs us, so all we do is use the function.
local Players = game.Players local id = 100 local nameOfPlayerWithId = Players:GetNameFromUserIdAsync(id) print(nameOfPlayerWithId) --// baltimoreclarke
See? Not too hard.
You should use pcall
for this in case the ID you provide isn't valid.
local succeeded, nameOfPlayerWithId = pcall(function() return Players:GetNameFromUserIdAsync(id) end)