There are a number of ways to get started to develop with ArcGIS Maps SDK for Java. If you are new, follow the steps below to get started with Java and IntelliJ IDEA.

1. Sign up for an account

To use ArcGIS Maps SDK for Java to access content Content is a collection of items in a portal that belong to a user, group, or organization. Learn more , services A service, also known as an ArcGIS service, is software that supports an ArcGIS REST API and provides geospatial functionality or data. A service can be hosted by Esri or in ArcGIS Enterprise. Learn more , or an organization, you need an ArcGIS Location Platform account An ArcGIS Location Platform account, formerly known as an ArcGIS Developer account, is an identity associated with an ArcGIS Location Platform subscription. Learn more , ArcGIS Online account An ArcGIS Online account, also known as an ArcGIS Organization account, is an identity associated with an ArcGIS Online subscription. It can be used to access ArcGIS tools and develop applications with ArcGIS location services for an organization. Learn more , or ArcGIS Enterprise account An ArcGIS Enterprise account is an identity for an instance of ArcGIS Enterprise. It can be used to access ArcGIS Enterprise tools, applications, and services, and to develop applications. Learn more . The type of account, user type, and role you need depends on the resource you need to access and the operations you wish to undertake.

If you do not have an account, select one of the options below:

Get a free account for ArcGIS Location Platform

Get an account for ArcGIS Online



2. Get the SDK and dependencies

To use the ArcGIS Maps SDK for Java you need to:

Install a supported JDK

  1. Download a JDK, filtering for your operating system, architecture, and version.
  2. Use the installation guide and follow the instructions.

Install a Java IDE with Gradle integrated

  1. Download and install IntelliJ IDEA Community Edition.

Get the ArcGIS Maps SDK for Java

  1. Expand the accordion below: Gradle build script.
  2. Copy the script into your Java project’s build.gradle file.
  3. Reload the build script and execute the run task to download and unpack the API dependencies.

For additional considerations, go to Install and set up.

plugins {
id 'application'
id 'org.openjfx.javafxplugin' version '0.1.0'
id 'idea'
}
idea {
module {
downloadJavadoc = true
}
}
ext {
arcgisVersion = '200.6.0'
}
repositories {
mavenCentral()
maven {
url 'https://esri.jfrog.io/artifactory/arcgis'
}
}
configurations {
natives
}
dependencies {
implementation "com.esri.arcgisruntime:arcgis-java:$arcgisVersion"
natives "com.esri.arcgisruntime:arcgis-java-jnilibs:$arcgisVersion"
natives "com.esri.arcgisruntime:arcgis-java-resources:$arcgisVersion"
// handle SLF4J http://www.slf4j.org/codes.html#StaticLoggerBinder using a no-operation logger
implementation "org.slf4j:slf4j-nop:2.0.16"
}
javafx {
version = "21.0.5"
modules = [ 'javafx.controls', 'javafx.graphics', 'javafx.fxml', 'javafx.web', 'javafx.media' ]
}
task copyNatives(type: Copy) {
description = "Copies the arcgis native libraries into the .arcgis directory for development."
group = "build"
configurations.natives.asFileTree.each {
from(zipTree(it))
}
into "${System.properties.getProperty("user.home")}/.arcgis/$arcgisVersion"
}
run {
dependsOn copyNatives
}

The copyNatives task in this Gradle build script will transfer all dependencies into a .arcgis folder located in the user’s home directory.

3. Get an access token

To access secure ArcGIS services and resources, you need to use an access token An access token is an authorization string that provides access to secure ArcGIS content, data, and services. Its capabilities are determined by the privileges it supports. It is obtained by implementing API key authentication, User authentication, or App authentication. Learn more . The easiest way to get started is to obtain an access token An access token is an authorization string that provides access to secure ArcGIS content, data, and services. Its capabilities are determined by the privileges it supports. It is obtained by implementing API key authentication, User authentication, or App authentication. Learn more from an API key An API key is a long-lived access token created using API key credentials. They are valid for up to one year and are typically embedded directly into client applications. Learn more . Learn more about access tokens and authentication in Security and authentication.

Create an API key

Implement user authentication

4. Create your first mapping application

Follow the step-by-step instructions in the Display a map tutorial to create your first mapping application. The following code shows how you can create and display a map.

// Authenticate with an API key access token or user authentication is required to access basemaps
// and other location services.
ArcGISRuntimeEnvironment.setApiKey("YOUR_ACCESS_TOKEN");
// Create a map with the standard imagery basemap style.
ArcGISMap map = new ArcGISMap(BasemapStyle.ARCGIS_IMAGERY_STANDARD);
// Create a new MapView object.
mapView = new MapView();
// Set the MapView with the map.
mapView.setMap(map);

Once you are done building your application, make sure to license it before deploying to production. For more information, see License and deployment topic for details.

5. Follow the tutorials

Go to the tutorials to create and run applications to perform different operations.

6. Explore the samples

Go to the samples to learn how to perform more tasks with the API.

Next steps