Use URL parameters

Experience Builder allows you to add URL parameters to your apps. You can use URL parameters to enhance an experience by making the URL set a locale, direct to a specific page, activate the print preview, and more.

Parameters are added to the end of the URL and are formatted as key-value pair connected with an equal sign. Experience Builder apps support parameters that are query strings, meaning they start with a question mark. To include multiple parameters, you must separate them with ampersands. Experience URLs with parameters use the following structure:

https://<domain>/experience/<AppID>/[?<param1=value>&<param2=value>&...]

The following is an example:

https://experience.arcgis.com/experience/<AppId>/

An experience's URL can include one or more of the parameters listed below.

General parameters

The following is a list of general URL parameters.

Switch locale

To switch the app language, use the locale parameter and a two-letter ISO 639-1 language code. Experience Builder supports all the same languages that ArcGIS Online supports, which includes the following language codes: ar, bg, bs, ca, cs, da, de, de-de, de-ch, el, en, en-au, en-ca, en-gb, en-us, es, es-es, es-mx, et, fi, fr, fr-fr, fr-ch, he, hr, hu, id, it, it-it, it-ch, ja, ko, lt, lv, nb, nl, pl, pt-br, pt-pt, ro, ru, sk, sl, sr, sv, th, tr, uk, vi, zh-cn, zh-hk, and zh-tw

To use an Experience Builder app in French and Switzerland French, you can append locale=fr to the URL, such as in the following examples:

https://experience.arcgis.com/experience/<AppId>/?locale=fr
https://experience.arcgis.com/experience/<AppId>/?locale=fr-ch
Note:

If you only assign a language without a detailed locale, such as fr instead of fr-ch or fr-fr, you are not guaranteed to obtain an expected date or number format. This is because different locales that speak the same language sometimes have different notations for dates and numbers, such as the United States (en-us) versus the United Kingdom (en-gb).

Go to a page

To direct to a specific page, use page followed by the page name. In ArcGIS Online Experience Builder apps, the page parameter is not part of a query string and does not follow a question mark. It is added in the URL path, such as in the following examples:

https://experience.arcgis.com/experience/<AppId>/page/Page-4
https://experience.arcgis.com/experience/<AppId>/page/{xxxHome}/

Go to a view

To direct to a specific active section view, use views followed by a view label such as v1 or View 1.

https://experience.arcgis.com/experience/<AppId>/?views=View-2
https://experience.arcgis.com/experience/<AppId>/?views=v1

Open a window

To direct to a specific active window, use dlg followed by a window ID or label.

https://experience.arcgis.com/experience/<AppId>/?dlg=Window-1

View draft mode

Whenever you preview an app, the draft parameter is automatically added. It allows you to obtain item resources for unpublished apps.

https://experience.arcgis.com/experience/<AppId>/?draft=true
https://experience.arcgis.com/experience/<AppId>/?draft=1

Open print preview

To activate print preview mode, use print_preview.

https://experience.arcgis.com/experience/<AppId>/?print_preview=true
https://experience.arcgis.com/experience/<AppId>/?print_preview=1

Data-related parameters

The following is a list of data-related URL parameters.

Provide a data source ID

Each data source in an app has its own data source ID. When you select a data record, the data source's ID is added to the app's URL, such as in the following examples:

https://experience.arcgis.com/experience/<AppId>/?data_id=<dsID>:<selectedrecordID>
https://experience.arcgis.com/experience/<AppId>/?data_id=dataSource_1-csv_966%3A0

You can use this method to find a layer's specific data source ID. For example, you can add a List widget and connect it to a layer, preview the app, and select any record in the list. The URL populates similar to the following example:

https://experience.arcgis.com/experience/<AppId>/?data_id=dataSource_2-Shelters_966%3Axxxxxx

The value after ?data_id= and before :<selectedrecordID> (or %3A<selectedrecordID>) is the layer's data source ID. Knowing the ID, you can use it with other parameters to filter the data source or change versions.

Filter data sources

To directly filter a data source, use data_filter. The filter format is a standard WHERE clause syntax that cannot contain "," or ":". To filter multiple data sources, use the format [<dsId:filter>,<dsId:filter>].

https://experience.arcgis.com/experience/<AppId>/?data_filter=dataSource_1:st=’HI’

The above URL is equal to the following encoded URL:

https://experience.arcgis.com/experience/<AppId>/?data_filter=dataSource_1:st=%27HI%27

The following is another example URL with this parameter:

https://experience.arcgis.com/experience/<AppId>/?data_filter=ds1:objectid=1,ds2:fielda>2

Change a data source's GDB version

To change a data source's GDB version, use data_version.

https://experience.arcgis.com/experience/<AppId>/?data_version=<dsId:version>,<dsId:version>
https://experience.arcgis.com/experience/<AppId>/?data_version=dsId1:v1, dsID2:v1

Login-related parameters

The following is a list of login-related URL parameters.

Share authentication through an Embed widget

Some web apps prompt users to sign in with an ArcGIS account. An app can require users to sign in because of its share settings, because the app includes widgets that use premium content, or for other reasons.

If you want to embed an ArcGIS web app in your Experience Builder app, and both require users to sign in, you can add the arcgis-auth-origin and arcgis-auth-portal URL parameters to share authentication between both apps so users only need to sign in once.

To embed a private Experience Builder app in another Experience Builder app, use ?arcgis-auth-origin= to define the host app domain URL for authentication. The following is an example:

https://<orgdomain>/experience/<AppID>/?arcgis-auth-origin=<your host app domain, such as https://localhost:3001>

To embed a JavaScript API-based app, such as a Web AppBuilder app, use the ?arcgis-auth-origin= for the host app domain authentication and ?arcgis-auth-portal= for the JavaScript API based app's domain authentication. The following are examples:

https://<orgdomain>/apps/webappviewer/index.html?id=<appID>&arcgis-auth-origin=<your host app domain, such as https://localhost:3001>&arcgis-auth-portal=<orgA URL>
https://www.arcgis.com/apps/opsdashboard/index.html#/<appID>?arcgis-auth-origin=https://experience.arcgis.com&arcgis-auth-portal=https://<myorg>.maps.arcgis.com

Send users to an organization sign-in page

In general, when users attempt to access a private Experience Builder app on ArcGIS Online, they are directed to the main ArcGIS Online sign-in page. To send users to your organization's sign-in page instead, use org followed by your organization's short name.

https://experience.arcgis.com/experience/<AppId>/?org=<yourorgshortname>