Map services represent a map that you've made available to others on a server. They are designed to work in many web and intranet scenarios. The same map service may be used in ArcGIS Pro by one user, a web app by another user, ArcGIS Online by another user, and a mobile app by still another user. For additional details about map services, see Publish a map service.
The following are some common reasons to set up a map service.
To serve dynamic maps
Dynamic maps are drawn at the time they are requested by a user. They are not as fast as cached maps, but they may be appropriate for highly focused intranet applications and applications that require real-time display of data.
To serve dynamic layers
Map services have built-in capabilities that allow clients, such as the ArcGIS web APIs, to dynamically change each layer's behavior and appearance. These dynamic layers can increase the amount of interaction that users can have with your maps on the web.
To serve cached maps
Cached map services (those that use a set of pre-created images) are the fastest way to serve maps on the web. This is how ArcGIS Online, Google Maps, Bing Maps, and many other services expose their maps. Although users will just be viewing static pictures of your map, you can supplement a cached map service with find, identify, and query tasks to reach the underlying data. You can also update the cache on a regular basis if your data changes.
Map services are not automatically cached; you must create the cache after you publish the service.
To serve features
Map services don't always need to display images. You can set up a map service for the purpose of returning a set of features to work within your app. You retrieve these features through tasks that you add to your app.
For example, you can query a map service and display the resulting features as a feature layer in the map. You can phrase this query as Give me all of the features with Delaware in the name, or Give me all of the features longer than 100 miles. Once you add the resulting features to a map, you can use labels or unique symbols to represent the features.
If you want to set up a map service to serve features, make sure the Query and Data operations are allowed.
To serve network analysis functions
You can set up a map service for the purpose of performing network analysis on the server. If your map document contains a network analysis layer, you'll see a network analysis capability that you can enable when you publish the service. You'll then have access to network analysis operations when developing apps to work with ArcGIS Server. You can set up default properties for the analysis in the map document, such as facilities and barriers.
To serve maps or features through KML
KML is a way of representing geographic data and maps through an open XML-based structure. KML is commonly used in geobrowser applications, such as ArcGIS Earth, to display map overlays or features, with attributes sometimes available in informational pop-up windows. All map services are able to return KML by default.
To serve images, features, or rasters through OGC specifications
The Open Geospatial Consortium has published specifications for exposing map images (WMS), vector features (WFS), raster datasets (WCS), and web map tiles (WMTS) on the web. Some organizations require their geographic data and maps to be available in this way. Map services can be configured to return images or data conforming to OGC specifications. See the section OGC service layers to learn more.
These are just some of the ways that you can use a map service. Through your own use of map services, you're likely to discover other uses. All map services are exposed through SOAP and REST interfaces, making them usable in many Esri and third-party applications.