Skip to content
Desktop inputOverview

getclipboard

Reads text from the system clipboard.

Details#

Reads desktop clipboard text. Returns an empty string when text is unavailable or the clipboard cannot be opened; an empty result therefore does not distinguish those cases.

Examples#

Example

Luau
local text = getclipboard()
print("Clipboard text length:", #text)