HOW TO
Using markers on a Map widget in an ArcGIS Experience Builder app can be a useful way to provide viewers with a clear point of reference. By highlighting a specific location when launching the experience, viewers can quickly orient themselves and focus on the area that is most relevant.
Within Experience Builder, this can be particularly useful when sharing an application centered on a specific area or point of interest, or guiding viewers directly to a feature without requiring them to manually search for it.
URL Parameters provide a customizable way to achieve this functionality.
This workflow can be done in both ArcGIS Online and in ArcGIS Enterprise, although the URL formats for Experience Builder items look slightly different.
The ArcGIS Online URL format to point to the desired Experience item is as follows:
https://experience.arcgis.com/experience/<experienceItemID>
In ArcGIS Enterprise, the URL format for an Experience item will look like:
https://<portalMachineName>/portal/apps/experiencebuilder/experience/?id=<experienceItemID>
These URL formats are the starting point for creating URLs with parameters to add a Marker to a Map Widget.
Note:
If you are using ArcGIS Experience Builder in ArcGIS Enterprise 11.5, this functionality may not work as expected. However, this behavior does not occur in ArcGIS Enterprise 12.1, and works as expected.
See: BUG-000187160
#<mapWidgetID>
followed by
=marker:<x>,<y>
#<mapWidgetID> defines what widget ID corresponds to the Map widget in your Experience. If the Map widget is added as the first widget in the experience, the map widget ID will be 1. The parameter in the URL would, therefore, look like #widget_1.Note:
If you are unsure of the widget ID for your map widget, you can use Developer Tools in a browser to find it.

=marker:<x>,<y> is the other required parameter to place a marker, as it is necessary to define coordinates for a point where the marker is located.
<wkid>
<title> <label>
<symbol>
Here is a template of the parameters to append to a URL for an Experience:
#<mapWidgetID>=marker:<x>,<y>;<wkid>;<label>;<symbol>
https://experience.arcgis.com/experience/123456789101112131415abcd#widget_1=marker:
-122.33%2C47.61

Note:
You may notice that instead of a comma (,) separating the x and y coordinates, "%2C" takes its place. When formatting your URL, it is important to note that some characters are considered preserved URL delimiters.
To ensure that the URL and the characters you enter are interpreted correctly, you will need to encode characters by replacing them with the UTF-8 hexadecimal equivalent. See the table below.
This table is a list of a few common characters that may be necessary to encode to include them in URL parameters:
| Encoded Value | Character |
| %2C | , |
| %3F | ? |
| %3B | ; |
| %2F | / |
| %3D | = |
| %3A | : |
| %5B | [ |
| %5D | ] |
| %7B | { |
| %7D | } |
| %23 | # |
| %27 | ' |
https://experience.arcgis.com/experience/123456789101112131415abcd#widget_1=marker:
-122.33%2C47.61;;;Seattle
Encoded, it will look like this:
https://experience.arcgis.com/experience/123456789101112131415abcd#widget_1=marker:
-122.33%2C47.61%3B%3B%3BSeattle

"type":"esriSMS","style":"esriSMSTriangle","color":[255,0,0,255],"size":12"type":"esriSLS","color":[0,0,255,255],"width":1https://experience.arcgis.com/experience/123456789101112131415abcd#widget_1=marker:
-122.33,47.61;;;Seattle;{"type":"esriSMS","style":"esriSMSTriangle","color":
[255,0,0,255],"size":12,"outline":{"type":"esriSLS","color":[0,0,255,255],"width":1}}
Encoded, it will look like this:
https://experience.arcgis.com/experience/123456789101112131415abcd#widget_1=marker:
-122.33%2C47.61%3B%3B%3BSeattle%3B%7B%22type%22%3A%22esriSMS%22%2C%22style%22%3A%22
esriSMSTriangle%22%2C%22color%22%3A%5B255%2C0%2C0%2C255%5D%2C%22size%22%3A12%2C%22
outline%22%3A%7B%22type%22%3A%22esriSLS%22%2C%22color%22%3A%5B0%2C0%2C255%2C255%5D
%2C%22width%22%3A1%7D%7D

These are just a few examples and possibilities of how to use URL parameters to add a marker to your map in ArcGIS Experience Builder! Additional customization options can be found in the documentation. Get creative!
Note: Some URL Parameters also have configurable options that are available through the Experience Builder web application. Authors can use the built-in configuration tools to add a marker to a map widget. This is a great option because setup is simplified, making it is easier to implement common URL parameter functionality without needing to edit the URL syntax directly.
Article ID: 000043430
Get help from ArcGIS experts
Start chatting now