Get started with the Spatial Analysis service

The Spatial Analysis service contains a number of tasks that allow you to perform common spatial analyses on your hosted data. An overview of the available tasks can be found in Overview of tasks contained in the Spatial Analysis service.

These tasks are also available as tools in the ArcGIS Online Map Viewer. These tools allow end-users to easily perform analysis against layers hosted in Online as well as other layers they have access to. To learn more about accessing these tasks using the ArcGIS Online Map Viewer, see the ArcGIS Online help topic Perform analysis. Note that in some cases, the Spatial Analysis REST API has more functionality that is not exposed in the ArcGIS Online Map Viewer.

Using these tasks consumes credits. For more information on credits, see Service credits overview.

Programmatically accessing analysis services shows you how to access these services using Python. To access the Spatial Analysis service using JavaScript, see the JavaScript API topic Working with Analysis Widgets.

You may want to visit the Analysis page on the ArcGIS Professional website. The Analysis page contains case studies that provide examples showing how analysis can be carried out using ArcGIS Online and ArcGIS Desktop.


In order to use the analysis tasks, the administrator of your organization needs to grant you certain privileges. To use any of the analysis tools, you will need the Spatial Analysis privilege. If the output of your task is a hosted feature service, as opposed to a feature collection, you also need the two following privileges:

  • Create, update, and delete content
  • Publish hosted features

Certain tasks need additional privileges such as Network Analysis and GeoEnrichment. If the task requires additional privileges, they will be listed in the task documentation.

Common patterns

The tasks in the Spatial Analysis service all share a common pattern.

  • One or more of their input parameters are features. These features can come from a feature service, map service, or in the form of a feature collection. See Feature Input for more information.
  • As described in Feature Output, all the spatial analysis tasks create new data. How data is returned to you is controlled by the outputName parameter.
  • All tasks have a context parameter which controls certain aspects of task execution. context has two properties; Extent and Spatial Reference.
  • All tasks execute asynchronously. That is, when you submit a request, you are handed back a job identifier which you can use to track progress and retrieve results. See Checking job status for more information.

In this topic
  1. Licensing
  2. Common patterns