Skip to content

Consume Central with SBT⚓︎

The default SBT configuration includes resolving components from the Central Repository via HTTP as documented in the library management documentation.

To access the Central Repository with sbt via HTTPS you can add a new resolver for the secured Central Repository, while disabling the default, in your build.sbt file

resolvers += "Secured Central Repository" at ""

externalResolvers := Resolver.withDefaultResolvers(resolvers.value, mavenCentral = false)

Alternatively you can add it as a global repository in ~/.sbt/repositories


and set when running sbt.