CrateDB and JDBC

Table of Contents


To find out which drivers are compatible to your CrateDB version, please consult the reference documentation.

Add CrateDB to Your Project

A simple way to configure your project to connect to a CrateDB cluster is to visit the JDBC driver page on Bintray and click the Set Me Up button. This will give you a Maven or Gradle configuration that can be pasted into your current project or downloaded for a new project.

For manual configuration follow these steps depending on your build system of choice.


Add the following to your pom.xml file:



Add CrateDB as a dependency to your Gradle file:

repositories {

 dependencies {
     compile 'io.crate:crate-jdbc:VERSION'

Connect to CrateDB

Connect to CrateDB Cluster with the Java DriverManager:

Connection conn = DriverManager.getConnection("crate://SERVER_IP:5432/");

Want to Know More?