26 min read

Source: Roblox Creator Hub · CC BY 4.0 · View source · Code samples: MIT Imported 2026-10-03. Formatting adapted for this site.

TeleportService

Inherits from: Instance → Object

TeleportService is responsible for transporting Players between different places and servers.

For more information on how to teleport players between servers, see Teleport between places.

Inherits from: Instance

Memory category: Instances

Tags: NotCreatable, Service

Properties

NameType / ReturnsDescription
TeleportService.CustomizedTeleportUIbooleanNo longer functional.

Inherited from Instance

NameType / ReturnsDescription
Instance.ArchivablebooleanDetermines if an Instance and its descendants can be cloned using Instance:Clone(), and can be saved/published.
Instance.archivableboolean
Instance.CapabilitiesSecurityCapabilitiesThe set of capabilities allowed to be used for scripts inside this container.
Instance.IsInSandboxbooleanIndicates whether the instance is inside a sandboxed container.
Instance.NamestringA non-unique identifier of the Instance.
Instance.ParentInstanceDetermines the hierarchical parent of the Instance.
Instance.PredictionModePredictionModeReflects the client-side prediction mode applied to the instance under server-authoritative physics.
Instance.RobloxLockedbooleanA deprecated property that used to protect CoreGui objects.
Instance.SandboxedbooleanWhen enabled, the instance can only access abilities in its Capabilities list.
Instance.UniqueIdUniqueIdA unique identifier for the instance.

Inherited from Object

NameType / ReturnsDescription
Object.ClassNamestringA read-only string representing the class this Object belongs to.
Object.classNamestring

TeleportService.CustomizedTeleportUI

Deprecated. This item is deprecated since the default message it controls has been removed. Do not use it for new work.

This property used to control whether or not a Message would be shown by default. The default message has been removed, so this no longer does anything.

FieldValue
typeboolean
tags["NotReplicated","Deprecated"]
security{"read":"None","write":"None"}
thread safetyReadSafe
categoryData
serialization{"can_load":true,"can_save":false}
capabilities["Teleport"]

Methods

NameType / ReturnsDescription
TeleportService:GetArrivingTeleportGuiInstanceReturns the customLoadingScreen the LocalPlayer arrived into the place with.
TeleportService:GetLocalPlayerTeleportDataVariantReturns the teleportData the Players.LocalPlayer arrived into the place with.
TeleportService:GetPlayerPlaceInstanceAsyncTupleReturns the PlaceId and JobId of the server the user with the given UserId is in provided it is in the same game as the current place.
TeleportService:GetTeleportSettingVariantRetrieves a teleport setting saved using TeleportService:SetTeleportSetting() using the given key.
TeleportService:PromptExperienceDetailsAsyncPromptExperienceDetailsResultPrompts a Player with information about the specified experience. The player can choose to teleport to the target experience through the prompt.
TeleportService:ReserveServerTupleReturns an access code that can be used to teleport players to a reserved server, along with the DataModel.PrivateServerId for it.
TeleportService:ReserveServerAsyncTupleReturns an access code that can be used to teleport players to a reserved server, along with the DataModel.PrivateServerId for it.
TeleportService:SetTeleportGui()Sets the custom teleport GUI that will be shown to the local user during teleportation, prior to the teleport being invoked.
TeleportService:SetTeleportSetting()Stores a value under a given key that persists across all teleportations in the same game.
TeleportService:Teleport()Teleports a Player to the place associated with the given placeId.
TeleportService:TeleportAsyncInstanceThe all-encompassing method to teleport a player or group of players from one server to another.
TeleportService:TeleportPartyAsyncstringTeleports a group of Players to the same server of the place with the given PlaceId, returning the JobId of the server instance they were teleported to.
TeleportService:TeleportToPlaceInstance()Teleports a Player to the server instance associated with the given placeId and instanceId.
TeleportService:TeleportToPrivateServer()Teleport a group of Players to a reserved server created using TeleportService:ReserveServerAsync().
TeleportService:TeleportToSpawnByName()A variant of TeleportService:Teleport() that causes the Player to spawn at a SpawnLocation of the given name at the destination place.

Inherited from Instance

NameType / ReturnsDescription
Instance:AddTag()Applies a tag to the instance.
Instance:childrenInstancesReturns an array of the object's children.
Instance:ClearAllChildren()This method destroys all of an instance's children.
Instance:CloneInstanceCreate a copy of an instance and all its descendants, ignoring instances that are not Archivable.
Instance:cloneInstance
Instance:Destroy()Sets the Instance.Parent property to nil, locks the Instance.Parent property, disconnects all connections, and calls Destroy() on all children.
Instance:destroy()
Instance:FindFirstAncestorInstance?Returns the first ancestor of the Instance whose Instance.Name is equal to the given name.
Instance:FindFirstAncestorOfClassInstance?Returns the first ancestor of the Instance whose Object.ClassName is equal to the given className.
Instance:FindFirstAncestorWhichIsAInstance?Returns the first ancestor of the Instance for whom Object:IsA() returns true for the given className.
Instance:FindFirstChildInstance?Returns the first child of the Instance found with the given name.
Instance:findFirstChildInstance
Instance:FindFirstChildOfClassInstance?Returns the first child of the Instance whose ClassName is equal to the given class name.
Instance:FindFirstChildWhichIsAInstance?Returns the first child of the Instance for whom Object:IsA() returns true for the given className.
Instance:FindFirstDescendantInstance?Returns the first descendant found with the given Instance.Name.
Instance:GetActorActor?Returns the Actor associated with the Instance, if any.
Instance:GetAttributeVariantReturns the value which has been assigned to the given attribute name.
Instance:GetAttributeChangedSignalRBXScriptSignalReturns an event that fires when the given attribute changes.
Instance:GetAttributesDictionaryReturns a dictionary of the instance's attributes.
Instance:GetChildrenInstancesReturns an array containing all of the instance's children.
Instance:getChildrenInstances
Instance:GetDebugIdstringReturns a coded string of the debug ID used internally by Roblox.
Instance:GetDescendantsInstancesReturns an array containing all of the descendants of the instance.
Instance:GetFullNamestringReturns a string describing the instance's ancestry.
Instance:GetStyledVariantReturns the styled or explicitly modified value of the specified property, or else the default property value if it hasn't been styled/modified.
Instance:GetStyledPropertyChangedSignalRBXScriptSignalReturns an event that fires when the given style property changes on the instance.
Instance:GetTagsArrayGets an array of all tags applied to the instance.
Instance:HasTagbooleanCheck whether the instance has a given tag.
Instance:IsAncestorOfbooleanReturns true if an Instance is an ancestor of the given descendant.
Instance:IsDescendantOfbooleanReturns true if an Instance is a descendant of the given ancestor.
Instance:isDescendantOfboolean
Instance:IsPropertyModifiedbooleanReturns true if the value stored in the specified property is not equal to the code-instantiated default.
Instance:QueryDescendantsInstancesReturns an array containing all descendants of the instance that match the selector string.
Instance:Remove()Sets the object's Parent to nil, and does the same for all its descendants.
Instance:remove()
Instance:RemoveTag()Removes a tag from the instance.
Instance:ResetPropertyToDefault()Resets a property to its default value.
Instance:SetAttribute()Sets the attribute with the given name to the given value.
Instance:WaitForChildInstanceReturns the child of the Instance with the given name. If the child does not exist, it will yield the current thread until it does.

Inherited from Object

NameType / ReturnsDescription
Object:GetPropertyChangedSignalRBXScriptSignalGet an event that fires when a given property of the object changes.
Object:IsAbooleanReturns true if an object's class matches or inherits from a given class.
Object:isAboolean

TeleportService:GetArrivingTeleportGui

This function returns the customLoadingScreen the LocalPlayer arrived into the place with.

Note, the customLoadingScreen will not be used if the destination place is in a different game.

Loading Screen

During a teleport, while the destination place is loading, the customLoadingScreen is parented to the CoreGui. Once the place has loaded the loading screen is parented to nil.

If you wish to preserve the customLoadingScreen and perform your own transitions, you will need to parent it to the local player's PlayerGui. For an example of this, see the code sample below.

Studio Limitation

Note that this service does not work during playtesting in Roblox Studio; to test aspects of your experience using it, you must publish the experience and play it in the Roblox application.

Returns

TypeDescription
InstanceThe customLoadingScreen the LocalPlayer arrived into the place with.
FieldValue
securityNone
thread safetyUnsafe
capabilities["UI","Teleport"]

Code samples: View on Creator Hub (handling-a-teleport-loading-gui).

TeleportService:GetLocalPlayerTeleportData

This function returns the teleport data the Players.LocalPlayer arrived with. It can only be called from the client.

Exploiters can spoof teleport data. Send secure data such as player currency through a server-side service such as DataStoreService to prevent tampering.

Returns

TypeDescription
VariantThe teleport data the Players.LocalPlayer arrived into the place with.
FieldValue
securityNone
thread safetyUnsafe
capabilities["Teleport"]

Code samples: View on Creator Hub (getting-LocalPlayer-teleport-data).

TeleportService:GetPlayerPlaceInstanceAsync

This function returns the PlaceId and JobId of the server the user with the given UserId is in, provided it is in the same game as the current place.

Then, TeleportService:TeleportToPlaceInstance() can be called with this information to allow a user to join the target user's server.

Upon a successful lookup, the function returns the following values:

# Name Type Description
1 currentInstance bool A bool indicating if the user was found in the current instance
2 error string An error message in the event of the lookup failing
3 placeId int64 The PlaceId of the server the user is in
4 instanceId string The JobId of the server the user is in

If there is a problem during lookup, such as the user being offline, an error is thrown. It is recommended that you wrap calls to this function in pcall.

Limitations

You should be aware of the following limitations when using this function:

Studio Limitation

Note that this service does not work during playtesting in Roblox Studio; to test aspects of your experience using it, you must publish the experience and play it in the Roblox application.

Parameters

NameTypeDefaultDescription
userIdUserThe Player.UserId of the Player.

Returns

TypeDescription
TupleSee the table above.
FieldValue
tags["Yields"]
securityNone
thread safetyUnsafe
capabilities["Teleport"]

Code samples: View on Creator Hub (following-a-player-in-a-universe).

TeleportService:GetTeleportSetting

This function retrieves a teleport setting saved using TeleportService:SetTeleportSetting() using the given key.

This method is intended for use on the client only and should not be used on the server.

Teleport settings are preserved across teleportations within the same game. This means data can be saved using TeleportService:SetTeleportSetting() in one place and retrieved using GetTeleportSetting in another place the user has been teleported to.

For example, in a game that allowed crouching you could save whether the user is currently crouching prior to teleporting as a teleport setting. This could then be retrieved in the destination place after the teleportation:

local TeleportService = game:GetService("TeleportService")

local isCrouching = TeleportService:GetTeleportSetting("isCrouching")

If no teleport setting exists under the given key, this function will return nil.

Differences from GlobalDataStores

Although they share some similarities, there are some key differences between teleport settings and datastores:

In general teleport settings should be used to preserve client side information within a single play session across different places in a game. GlobalDataStores should be used to save

Teleport settings and security

As teleport settings are stored locally, it is possible they can be manipulated by malicious users. This risk can be mitigated by employing server side validation.

Studio Limitation

Note that this service does not work during playtesting in Roblox Studio; to test aspects of your experience using it, you must publish the experience and play it in the Roblox application.

Parameters

NameTypeDefaultDescription
settingstringThe key the value was stored under using TeleportService:SetTeleportSetting().

Returns

TypeDescription
VariantThe value stored under the given key.
FieldValue
securityNone
thread safetyUnsafe
capabilities["Teleport"]

TeleportService:PromptExperienceDetailsAsync

Prompts the specified Player with information of the specified experience. The prompt includes the experience name, creator name, maturity rating, etc. The prompt also includes a Join button which the player can use to be teleported to the target experience. If the player is ineligible to join the target experience, the button will be disabled.

Any teleport failures after the player clicks the Join button will also fire TeleportService.TeleportInitFailed providing a reason for the failure.

Limitations

Parameters

NameTypeDefaultDescription
playerPlayerThe Player to be presented the prompt.
universeIdint64DataModel.UniverseId of the experience to be presented to the Player.

Returns

TypeDescription
PromptExperienceDetailsResultPromptExperienceDetailsResult
FieldValue
tags["Yields"]
securityNone
thread safetyUnsafe
capabilities["Teleport"]

Code samples: View on Creator Hub (present-experience-details-page).

TeleportService:ReserveServer

Deprecated. Use ReserveServerAsync() instead.

Returns an access code that can be used to teleport players to a reserved server, along with the DataModel.PrivateServerId for it.

Parameters

NameTypeDefaultDescription
placeIdint64The DataModel.PlaceId of the place the reserved server is being created for.

Returns

TypeDescription
TupleThe server access code required by TeleportService:TeleportToPrivateServer() and the DataModel.PrivateServerId for the reserved server.
FieldValue
tags["Yields","Deprecated"]
securityNone
thread safetyUnsafe
capabilities["Teleport"]

Code samples: View on Creator Hub (TeleportService-ReserveServer1, teleportservice-teleport-to-a-reserved-server-via-chat).

TeleportService:ReserveServerAsync

This function returns an access code that can be used to teleport players to a reserved server, along with the server's DataModel.PrivateServerId. It can only be called on the server.

Reserved Servers

You can access reserved servers using:

You can see if the current server is a reserved server by using the following code:

local isReserved = game.PrivateServerId ~= "" and game.PrivateServerOwnerId == 0

The DataModel.PrivateServerId is constant across all server instances associated with the server access code, the DataModel.JobId is not.

Studio Limitation

Note that this service does not work during playtesting in Roblox Studio; to test aspects of your experience using it, you must publish the experience and play it in the Roblox application.

Cross-Platform Play

Players on Xbox and PlayStation with cross‑play disabled will arrive in a different server than players with cross‑play enabled. This can cause multiple game servers with the same PrivateServerId to exist. You can use DataModel.MatchmakingType to differentiate these game servers.

Parameters

NameTypeDefaultDescription
placeIdint64The DataModel.PlaceId of the place the reserved server is being created for.

Returns

TypeDescription
TupleThe server access code required by TeleportService:TeleportToPrivateServer() and the DataModel.PrivateServerId for the reserved server.
FieldValue
tags["Yields"]
securityNone
thread safetyUnsafe
capabilities["Teleport"]

Code samples: View on Creator Hub (TeleportService-ReserveServer1, teleportservice-teleport-to-a-reserved-server-via-chat).

TeleportService:SetTeleportGui

This function sets the custom teleport GUI that will be shown to the local user during teleportation, prior to the teleport being invoked.

Note, the teleport GUI will not be used if the destination place is in a different game. It will also not persist across multiple teleports and will need to be set prior to each one.

This function should only be used on the client. If the teleportation function is called from the server (as is the case with TeleportService:TeleportAsync()) then this function should be called on the client prior to this. One way of doing this is listening to a RemoteEvent that fires several seconds before teleportation.

Loading screen

During a teleport, while the destination place is loading, the customLoadingScreen is parented to the CoreGui. Once the place has loaded the loading screen is parented to nil.

This ScreenGui can be fetched at the destination place using TeleportService:GetArrivingTeleportGui(), allowing you to parent it to the PlayerGui and perform your own transitions.

You are advised to also parent the ScreenGui to the PlayerGui in the start place while the teleport is initiating.

External references

The teleport GUI and all of its descendants are carried to the destination place, but any property that references an Instance outside the GUI's own tree is cleared during the teleport. For example, a Sound inside the GUI whose SoundGroup points to a SoundGroup under SoundService will arrive with that reference set to nil, because the target lives outside the GUI and cannot safely cross the boundary between servers.

References that point to other instances within the GUI tree are preserved. If your loading screen depends on an external instance, recreate that instance inside the GUI tree.

Studio Limitation

Note that this service does not work during playtesting in Roblox Studio; to test aspects of your experience using it, you must publish the experience and play it in the Roblox application.

Parameters

NameTypeDefaultDescription
guiInstanceThe loading ScreenGui that is to be displayed during teleportation.

Returns

TypeDescription
()
FieldValue
securityNone
thread safetyUnsafe
capabilities["UI","Teleport"]

Code samples: View on Creator Hub (teleporting-the-local-player).

TeleportService:SetTeleportSetting

This function stores a value under a given key that persists across all teleportations in the same game.

This method is intended for use on the client only and should not be used on the server.

The stored value can later be retrieved using TeleportService:GetTeleportSetting(). This will work in the current place and any subsequent places the Players.LocalPlayer teleports to, provided they are in the same game.

For example, in a game that allowed crouching you could save whether the user is currently crouching prior to teleporting as a teleport setting:

local TeleportService = game:GetService("TeleportService")

local isCrouching = false
TeleportService:SetTeleportSetting("isCrouching", isCrouching)

The stored value may only contain value types. It cannot contain Instances or other types that reference engine state, as these cannot safely cross the boundary between servers.

Allowed values:

Not allowed (these will be removed before the teleport completes):

If a stored setting contains a disallowed type, that value is removed and an error is written to the developer console. Convert instance references to plain values (for example, a numeric ID or a string path).

If data is already stored under the given key, the previous value will be overwritten by the new value.

Differences from GlobalDataStores

Although they share some similarities, there are some key differences between teleport settings and datastores:

In general teleport settings should be used to preserve client side information within a single play session across different places in a game. GlobalDataStores should be used to save

Teleport settings and security

As teleport settings are stored locally, it is possible they can be manipulated by malicious users. This risk can be mitigated by employing server side validation.

Studio Limitation

Note that this service does not work during playtesting in Roblox Studio; to test aspects of your experience using it, you must publish the experience and play it in the Roblox application.

Parameters

NameTypeDefaultDescription
settingstringThe key to store the value under. This key can be used to retrieve the value using TeleportService:GetTeleportSetting().
valueVariantThe value to store.

Returns

TypeDescription
()
FieldValue
securityNone
thread safetyUnsafe
capabilities["Teleport"]

TeleportService:Teleport

Deprecated. Use TeleportAsync() for server-side teleports. For client-side teleports, use a RemoteEvent to signal the server to call TeleportAsync(). For a migration guide, see Teleport between places.

This method should not be used for new work; the numerous teleport functions have been combined into a single method, TeleportAsync(), which should be used instead.

Parameters

NameTypeDefaultDescription
placeIdint64The ID of the place to teleport to.
playerInstancenilThe Player to teleport, if this function is being called from the client this defaults to the Players.LocalPlayer.
teleportDataVariantOptional data to be passed to the destination place. Can be retrieved using TeleportService:GetLocalPlayerTeleportData().
customLoadingScreenInstancenilOptional custom loading screen to be placed in the CoreGui at the destination place. Can be retrieved using TeleportService:GetArrivingTeleportGui().

Returns

TypeDescription
()
FieldValue
securityNone
thread safetyUnsafe
capabilities["UI","Teleport"]

Code samples: View on Creator Hub (teleporting-the-local-player, teleporting-from-the-server).

TeleportService:TeleportAsync

This function serves as the all-encompassing method to teleport a player or group of players from one server to another. It can be used to:

Server-Only

This method can only be called from the server. If you need to initiate a teleport from the client, use a RemoteEvent to signal the server, then call TeleportService:TeleportAsync() from a server Script. Client-side teleports using TeleportService:Teleport() is not recommended for new work. See Teleport between places for more information.

Group Teleport Limitations

Potential Errors

This is a list of potential reasons a teleport may fail, ranging from invalid teleports to network issues.

Error Description
Invalid placeId The provided place ID is below 0.
Players empty The provided list of players to teleport is empty.
List of players instances is incorrect Any of the provided players is not a Player object.
TeleportOptions not of correct type The provided teleportOption is not a TeleportOptions object.
TeleportAsync called from Client The client called TeleportAsync, which can only be called from the server.
Incompatible Parameters Conflicting teleport options were used and TeleportService doesn't know where to send the player.

Conflicting TeleportOption parameters:
* ReservedServerAccessCode and ServerInstanceId
* ShouldReserveServer and ServerInstanceId
* ShouldReserveServer and ReservedServerAccessCode

For more information on how to teleport players between servers and receive user data from a teleport, see Teleport between places.

Parameters

NameTypeDefaultDescription
placeIdint64The place ID the player(s) should be teleported to.
playersInstancesAn array of the player(s) to teleport.
teleportOptionsInstancenilAn optional TeleportOptions object containing additional arguments to the TeleportService:TeleportAsync() call. If this is not passed, no result will be returned.

Returns

TypeDescription
InstanceIf a TeleportOptions parameter is passed, this will be a TeleportAsyncResult object that provides information about the final teleport destination.
FieldValue
tags["Yields"]
securityNone
thread safetyUnsafe
capabilities["UI","Teleport"]

TeleportService:TeleportPartyAsync

Deprecated. Use TeleportAsync() instead. For a migration guide, see Teleport between places.

This method should not be used for new work; the numerous teleport functions have been combined into a single method, TeleportAsync(), which should be used instead.

Parameters

NameTypeDefaultDescription
placeIdint64The ID of the place to teleport to.
playersInstancesAn array containing the Players to teleport.
teleportDataVariantOptional data to be passed to the destination place. Can be retrieved using TeleportService:GetLocalPlayerTeleportData().
customLoadingScreenInstancenilOptional custom loading screen to be placed in the CoreGui at the destination place. Can be retrieved using TeleportService:GetArrivingTeleportGui().

Returns

TypeDescription
stringThe DataModel.JobId of the server instance the Players were teleported to.
FieldValue
tags["Yields","Deprecated"]
securityNone
thread safetyUnsafe
capabilities["UI","Teleport"]

Code samples: View on Creator Hub (teleport-all-players-in-the-server).

TeleportService:TeleportToPlaceInstance

Deprecated. Use TeleportAsync() instead. For a migration guide, see Teleport between places.

This method should not be used for new work; the numerous teleport functions have been combined into a single method, TeleportAsync(), which should be used instead.

Parameters

NameTypeDefaultDescription
placeIdint64The ID of the place to teleport to.
instanceIdstringThe DataModel.JobId of the server instance to teleport to.
playerInstancenilThe Player to teleport, if this function is being called from the client this defaults to the Players.LocalPlayer.
spawnNamestringOptional name of the SpawnLocation to spawn at.
teleportDataVariantOptional data to be passed to the destination place. Can be retrieved using TeleportService:GetLocalPlayerTeleportData().
customLoadingScreenInstancenilOptional custom loading screen to be placed in the CoreGui at the destination place. Can be retrieved using TeleportService:GetArrivingTeleportGui().

Returns

TypeDescription
()
FieldValue
tags["Deprecated"]
securityNone
thread safetyUnsafe
capabilities["UI","Teleport"]

Code samples: View on Creator Hub (following-a-player-in-a-universe).

TeleportService:TeleportToPrivateServer

Deprecated. Use TeleportAsync() instead. For a migration guide, see Teleport between places.

This method should not be used for new work; the numerous teleport functions have been combined into a single method, TeleportAsync(), which should be used instead.

Parameters

NameTypeDefaultDescription
placeIdint64The ID of the place to teleport to.
reservedServerAccessCodestringThe reserved server access code returned by TeleportService:ReserveServerAsync().
playersInstancesAn array of Players to teleport.
spawnNamestringOptional name of the SpawnLocation to spawn at.
teleportDataVariantOptional data to be passed to the destination place. Can be retrieved using TeleportService:GetLocalPlayerTeleportData().
customLoadingScreenInstancenilOptional custom loading screen to be placed in the CoreGui at the destination place. Can be retrieved using TeleportService:GetArrivingTeleportGui().

Returns

TypeDescription
()
FieldValue
tags["Deprecated"]
securityNone
thread safetyUnsafe
capabilities["UI","Teleport"]

Code samples: View on Creator Hub (teleportservice-teleport-to-a-reserved-server-via-chat, TeleportService-ReserveServer1).

TeleportService:TeleportToSpawnByName

Deprecated. Use TeleportAsync() instead. For a migration guide, see Teleport between places.

This method should not be used for new work; the numerous teleport functions have been combined into a single method, TeleportAsync(), which should be used instead.

Parameters

NameTypeDefaultDescription
placeIdint64The ID of the place to teleport to.
spawnNamestringThe name of the SpawnLocation to spawn at.
playerInstancenilThe Player to teleport, if this function is being called from the client this defaults to the Players.LocalPlayer.
teleportDataVariantOptional data to be passed to the destination place. Can be retrieved using TeleportService:GetLocalPlayerTeleportData().
customLoadingScreenInstancenilOptional custom loading screen to be placed in the CoreGui at the destination place. Can be retrieved using TeleportService:GetArrivingTeleportGui().

Returns

TypeDescription
()
FieldValue
tags["Deprecated"]
securityNone
thread safetyUnsafe
capabilities["UI","Teleport"]

Code samples: View on Creator Hub (TeleportService-TeleportToSpawnByName1).

Events

NameType / ReturnsDescription
TeleportService.LocalPlayerArrivedFromTeleportFires when the LocalPlayer enters the place following a teleport.
TeleportService.TeleportInitFailedFires when a teleport fails to start, leaving the player in their current server.

Inherited from Instance

NameType / ReturnsDescription
Instance.AncestryChangedFires when the Instance.Parent property of this object or one of its ancestors is changed.
Instance.AttributeChangedFires whenever an attribute is changed on the Instance.
Instance.ChildAddedFires after an object is parented to this Instance.
Instance.childAdded
Instance.ChildRemovedFires after a child is removed from this Instance.
Instance.DescendantAddedFires after a descendant is added to the Instance.
Instance.DescendantRemovingFires immediately before a descendant of the Instance is removed.
Instance.DestroyingFires immediately before (or is deferred until after) the instance is destroyed via Instance:Destroy().
Instance.StyledPropertiesChangedFires whenever any style property is changed on the instance, including when a property is set to nil.

Inherited from Object

NameType / ReturnsDescription
Object.ChangedFires immediately after a property of the object changes, with some limitations.

TeleportService.LocalPlayerArrivedFromTeleport

This function fires when the Players.LocalPlayer enters the place following a teleport. The teleportData and customLoadingScreen are provided as arguments.

When fetching teleportData and the customLoadingScreen you are advised to use TeleportService:GetLocalPlayerTeleportData() and TeleportService:GetArrivingTeleportGui() instead. This is because these functions can be called immediately without having to wait for this event to fire.

This event should be connected immediately in a LocalScript parented to ReplicatedFirst. Otherwise, when the connection is made the event may have already fired.

Loading Screen

During a teleport, while the destination place is loading, the customLoadingScreen is parented to the CoreGui. Once the place has loaded the loading screen is parented to nil.

If you wish to preserve the customLoadingScreen and perform your own transitions, you will need to parent it to the local player's PlayerGui. For example, using the following code inside a LocalScript in ReplicatedFirst:

local TeleportService = game:GetService("TeleportService")
local Players = game:GetService("Players")
local ReplicatedFirst = game:GetService("ReplicatedFirst")

TeleportService.LocalPlayerArrivedFromTeleport:Connect(function(customLoadingScreen, teleportData)
	local playerGui = Players.LocalPlayer:WaitForChild("PlayerGui")
	ReplicatedFirst:RemoveDefaultLoadingScreen()

	customLoadingScreen.Parent = playerGui
	-- animate screen here
	wait(5)
	-- destroy screen
	customLoadingScreen:Destroy()
end)

The customLoadingScreen will not be used if the destination place is in a different game.

Studio Limitation

Note that this service does not work during playtesting in Roblox Studio; to test aspects of your experience using it, you must publish the experience and play it in the Roblox application.

Parameters

NameTypeDefaultDescription
loadingGuiInstanceThe customLoadingScreen the LocalPlayer arrived into the place with.
dataTableVariantThe teleportData the LocalPlayer arrived into the place with.
FieldValue
securityNone
capabilities["Teleport"]

TeleportService.TeleportInitFailed

This event fires on both the client and the server when a request to teleport from a function such as TeleportService:TeleportAsync() fails and the player does not leave the current server. It provides a reason for the failure, as well as all of the information necessary to retry the teleport. If a group teleport fails, the event will fire once per player.

TeleportOptions

The TeleportOptions object provided by this event is not identical to the one passed to the original TeleportService:TeleportAsync() call. It is a new object populated with the necessary parameters to retry the teleport and send the player to the exact same destination. This is especially important for facilitating group teleports when they fail.

Original Teleport Type Teleport Data ReservedServerAccessCode ServerInstanceId ShouldReserveServer
Individual player to place Original value None None false
Player(s) to reserved server Original value Original value, or the code generated if ShouldReserveServer was originally true None false
Player(s) to specific server Original value None Original value false
Players to place Original value None Same destination ID as the other players in the original teleport false

For more information on how to teleport players between servers, see Teleport between places.

Parameters

NameTypeDefaultDescription
playerInstanceThe Player instance that failed to teleport.
teleportResultTeleportResultThe reason for the teleport failure.
errorMessagestringThe message provided to the player explaining the teleport failure.
placeIdint64The original target place ID of the teleport.
teleportOptionsInstanceA TeleportOptions object that can be passed back to TeleportService:TeleportAsync() to retry the failed teleport.
FieldValue
securityNone
capabilities["Teleport"]