Skip to main content
DEPRECATION NOTICE: This entire page documents the legacy Text manipulation system. For new projects: Use Data Binding instead. For existing projects: Plan to migrate from direct text run manipulation to Data Binding as soon as possible.
For more information on designing and animating Text, please refer to the editor’s text section:

Read/Update Text Runs at Runtime

⚠️ LEGACY CONTENT WARNING: The following sections document the deprecated Text manipulation system. This content is provided for legacy support only. New implementations should use Data Binding.
If you intend to update a text run at runtime it’s important to manually enter a unique name for the run in the editor: Image And then export the name: right-click and select Export name Image You can identify an exported component if it’s surrounded by square brackets. This makes it possible for the run to be “discoverable” at runtime by its name. For more information, see Exporting for Runtime.
If the name is not set manually in the editor the name will not be part of the exported .riv (to reduce file size).
Text runs can also be updated on components at runtime, see Read/Update Nested Text Runs at Runtime below.

Update Rive Text in Unity

A unique run name must be set in the editor to be easily discoverable at runtime. See the text runtime docs for more information.
A text run can be updated from an artboard instance by providing the name and new value:
Artboard artboard;

....

artboard.SetTextRun("textRunName", "newValue");
Note: This API only updates text runs on the given artboard, and will not update text runs on component instances.

Nested Text Runs

For more information about updating nested text runs in Unity, take a look at this example.