Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?


Failed to load latest commit information.
Latest commit message
Commit time

pitaya Build Status Coverage Status GoDoc Docs Go Report Card MIT licensed

WARNING: The version v1.x of pitaya is deprecated, complete guide of the new version v2.x can be found here. The current README is for version 2, make sure you look at branch v1 if you'd like to see the documentation for the older version.

Pitaya is an simple, fast and lightweight game server framework with clustering support and client libraries for iOS, Android, Unity and others through the C SDK. It provides a basic development framework for distributed multiplayer games and server-side applications.

Getting Started


  • Go >= 1.16
  • etcd (optional, used for service discovery)
  • nats (optional, used for sending and receiving rpc)
  • docker (optional, used for running etcd and nats dependencies on containers)


clone the repo

git clone

setup pitaya dependencies

make setup

Hacking pitaya

Here's one example of running Pitaya:

Start etcd (This command requires docker-compose and will run an etcd container locally. An etcd may be run without docker if prefered.)

cd ./examples/testing && docker-compose up -d etcd

run the connector frontend server from cluster_grpc example

make run-cluster-grpc-example-connector

run the room backend server from the cluster_grpc example

make run-cluster-grpc-example-room

Now there should be 2 pitaya servers running, a frontend connector and a backend room. To send requests, use a REPL client for pitaya pitaya-cli.

$ pitaya-cli
Pitaya REPL Client
>>> connect localhost:3250
>>> request
>>> sv-> {"code":0,"result":"ok"}

Running the tests

make test

This command will run both unit and e2e tests.




  • TFG Co - Initial work


MIT License


  • nano authors for building the framework pitaya is based on.
  • pomelo authors for the inspiration on the distributed design and protocol


If you have found a security vulnerability, please email