Built-in URL parameters
Learn about built-in URL parameters to control app behavior.
Public apps do not support built-in URL parameters.
Use built-in URL search parameters to control certain app characteristics when launched, such as loading a specific release or environment. Append ? to the app's URL and include the parameters as key=value pairs. Separate multiple parameters with &.
Refer to the URL parameters guide for information on configuring custom parameters for use in apps.
Appending _releaseVersion=latest to the URL can show unpublished changes. By default, app URLs load the most recent live (published) version. If you share a URL with ?_releaseVersion=latest, Retool loads the latest saved edit instead, including unpublished changes.
This means viewers and other end users can see draft edits that are not published yet.
All properties for this object with supported data types or values. You can write JavaScript almost anywhere in Retool to manipulate or read property values.
_embed
Hides all non-app UI elements, such as the Retool header.
| Type | boolean |
| Format | True/False |
| Configurability | Read-only |
| Default | false |
Examples
falsetrue
_environment
The environment to load (e.g., staging).
| Type | string |
| Format | Plain Text |
| Configurability | Read-only |
| Default | production |
Examples
false"staging"
_hideNav
Hides the Retool navigation bar.
| Type | boolean |
| Format | True/False |
| Configurability | Read-only |
| Default | false |
Examples
falsetrue
_hideTimer
Hides the status bar which contains the query timer.
| Type | boolean |
| Format | True/False |
| Configurability | Read-only |
| Default | false |
Examples
falsetrue
_historyOffset
Opens the Retool app to a previous point in its save history state. Only applies when launching an app with the latest release version.
| Type | number |
| Format | integer |
| Configurability | Read-only |
| Default | null |
Examples
false1
_releaseVersion
The app version to load. By default (when this parameter is not set), Retool loads the most recent live (published) version of the app. If no live version exists, Retool falls back to the latest saved edit. Use _releaseVersion=latest to explicitly load the latest saved edit, including unpublished changes.
| Type | string |
| Format | Plain Text |
| Configurability | Read-only |
| Default | most recent live (published) version |
Examples
false"v1.0.0"
false"latest"
Set URL parameters with JavaScript
Use utils.setUrlParameters() to programmatically update the current page's URL search and hash parameters. Changes are reflected immediately in the url object and in the browser's address bar without triggering a page reload.
utils.setUrlParameters({
queryParams: [
{ key: 'role', value: 'viewer' },
{ key: 'team', value: 'workplace' },
],
hashParams: [
{ key: 'enabled', value: 'true' },
],
});
After this runs, the URL updates to include ?role=viewer&team=workplace#enabled=true, and you can reference the values using {{ url.searchParams.role }} and {{ url.hashParams.enabled }}.
You can omit either queryParams or hashParams to update only one type at a time. Pass an empty array to clear all parameters of that type.