We use cookies on this site to enhance your user experience
Collapse Sidebar


The LoadAsset function fetches an asset given its ID and returns a Model inserted into InsertService containing the asset.

The given asset must be created by you or Roblox, otherwise the function will error.

For instance, if you want to load a Doge Model, which has the asset Id 257489726, you would use the following statement:


This line would return an Instance of the Doge model within your game. Changing the asset Id passed as an argument changes the asset that is loaded into your game.


There are limitations on loading packages. Use AssetService/GetAssetIdsForPackage to get asset IDs of a package, then insert them one at a time using this function.


Occasionally, an asset may fail to load. It’s a good idea to wrap calls to this function in pcall to catch these kinds of errors:

local success, model = pcall(function ()
    return InsertService:LoadAsset(257489726)
if success then
    print("Model loaded!")
    model.Parent = workspace
    print("Model failed to load")

See also

To find Free Models or Decal|Decals to insert into your game, you can use the InsertService/GetFreeModels and InsertService/GetFreeDecals functions. For plugins, see DataModel/GetObjects.


Name Type Default Description

The asset Id of the asset being loaded


Return Type Summary

An instance of the loaded asset

Code Samples


local assetId = 82353
game:GetService("InsertService"):LoadAsset(assetId).Parent = game.Workspace