Service contains unsafe html content - [Description]

Last Published: April 25, 2020

Error Message

Creating a New Hosted Feature Layer from My Content using the option for From URL fails and results in the following error. This error is typically seen when entering the URL of a feature service that has been published from ArcGIS Pro.

Service contains unsafe html content - [Description].
An image of the error message as it appears in ArcGIS Online.


This error occurs if text has been entered in the Description field of the Metadata tab within the Map or Layer properties in ArcGIS Pro when the feature service is published to ArcGIS Online. During the publishing process, inline HTML elements are added to the Description text and stored in the JSON of the feature service. This syntax can be seen through the JSON view of the REST endpoint, after the service has been published. This example below shows how the Description is altered during the publishing process:

\u003cDIV STYLE=\"text-align:Left;font-size:12pt\"\u003e\u003cDIV\u003e\u003cDIV\u003e\u003cP\u003e\u003cSPAN\Description of the feature service...\
Note: To view the REST endpoint of a service in JSON format, browse to the REST endpoint and click 'JSON' at the top of the page.
The following workflows for publishing from ArcGIS Pro show this error:
  • The Map is published as a Web Layer and there is text in the Description of the Map.
  • The Layer is published as a Web Layer and there is text in the Description of the Layer.
The error does not occur if the map is published as a web layer and there is text in the Description of the layer(s), but no text is present in the description of the map.

This is a known issue. The irregular HTML formatting is not recognized as valid JSON content and therefore is considered unsafe. As a result, the error message displays when ArcGIS Online attempts to publish the feature service.

Solution or Workaround

As a workaround, remove the text from the Description field in ArcGIS Pro before publishing the map or layer to ArcGIS Online. Instead, add the Description in the Item Details page of the published service in ArcGIS Online.

To access the Description in ArcGIS Pro, right-click the map or layer in the Contents pane, and select Properties. When the Layer Properties window displays, select Metadata.

Article ID:000014289

  • ArcGIS Online
  • ArcGIS Pro 1 x

Receive notifications and find solutions for new or common issues

Get summarized answers and video solutions from our new AI chatbot.

Download the Esri Support App

Related Information

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options