Gocb: The Couchbase Go SDK

Couchbase Go Client

The Go SDK library allows you to connect to a Couchbase cluster from Go. It is written in pure Go, and uses the included gocbcore library to handle communicating to the cluster over the Couchbase binary protocol.


To install the latest stable version, run:

go get github.com/couchbase/gocb/v2@latest

To install the latest developer version, run:

go get github.com/couchbase/gocb/v2@master


You can run tests in the usual Go way:

go test -race ./...

Which will execute both the unit test suite and the integration test suite. By default, the integration test suite is run against a mock Couchbase Server. See the testmain_test.go file for information on command line arguments for running tests against a real server instance.

Release train

Releases are targeted for every third Tuesday of the month. This is subject to change based on priorities.


Linting is performed used golangci-lint. To run:

make lint

Useful Links


The project source is hosted at https://github.com/couchbase/gocb.


You can explore our API reference through godoc at https://pkg.go.dev/github.com/couchbase/gocb.

You can also find documentation for the Go SDK on the official Couchbase docs.

Bug Tracker

Issues are tracked on Couchbase's public issues.couchbase.com. Contact the site admins regarding login or other problems at issues.couchbase.com (officially) or ask around on the forum (unofficially).


You can chat with us on Discord or the official Couchbase forums.

Download Details:

Author: Couchbase
Source Code: https://github.com/couchbase/gocb 
License: Apache-2.0 license

#go #golang #sdk 

Gocb: The Couchbase Go SDK
1.00 GEEK