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




This property determines whether a GuiObject|GUI will render shapes, images and/or text on screen. If set to false, the GUI and all of its descedants (children) will not render.

The rendering of individual components of a GUI can be controlled individually through transparency properties such as GuiObject/BackgroundTransparency, TextLabel/TextTransparency and ImageLabel/ImageTransparency.

When this property is true, the GUI will be ignored by UIGridStyleLayout objects (such as UIGridLayout, UIListLayout and UITableLayout). In other words, the space that the element would otherwise occupy in the layout is used by other elements instead.

Code Samples

Blink UI Element

This code sample blinks a UI element on/off, much like HTML’s beloved tag. They still have that, right?

local guiObject = script.Parent

while true do
	guiObject.Visible = true
	guiObject.Visible = false

UI Window

This code sample adds open/close functionality to a Window UI. Paste as a LocalScript that is a sibling of a Frame named Window, a TextButton/ImageButton named Window, and a TextButton/ImageButton within the Window called Close.

local gui = script.Parent
local window = gui:WaitForChild("Window")
local toggleButton = gui:WaitForChild("ToggleWindow")
local closeButton = window:WaitForChild("Close")

local function toggleWindowVisbility()
	-- Flip a boolean using the `not` keyword
	window.Visible = not window.Visible