Skip to content
An open and decentralized private social network
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Gravity is an open and decentralized private social network.

Why does it have to be decentralized?

Do we really need yet another social network? Surely this space is over-saturated...

  • Short answer: We looked really hard but couldn't find anything that was private, didn't rely on any third parties, and was more than just a messenger.
  • Long answer: Check out our extensive survey which resulted from that research.

This repo is a sample implementation of the protocol underlying the Gravity social network. Since it's open and decentralized, anyone can participate; you don't need to go through or even use this code to do so.


This software is still in alpha, and as we all know, software is made of bugs. (If you find one, please open an issue!)

Breaking changes to the protocol/interface will occur, but we will always provide a mitigation path to avoid losing any user data.

This protocol has not undergone an independent professional security audit. We think it's secure, but I'd avoid using it for anything illegal.


npm install --save gravity-protocol

Or to build from source, clone the repo then npm install in the root directory.


const GravityProtocol = require('gravity-protocol');
const gp = new GravityProtocol();
gp.ready.then(() => {
	const myIdentity = {id: gp.getIpnsId(), publicKey: gp.getPublicKey()};

For a real example of the protocol in use and interacting with the rest of the network, see gravity-minimal.


Contributions are welcome! Feel free to open PRs, just make sure to always lint with npm run lint-fix please.


Drop us a line at! We accept...

  • of any kind
  • ...bug reports (although those are best as issues)
  • ...suspected security vulnerabilities
  • ...musings on the future of the internet, connectivity, and human interaction
  • ...anything really, we're always happy to hear from our users



Gravity relies very heavily upon IPFS and libp2p, together an ambitious open source project to re-decentralize the internet, and one for which we are very grateful.

You can’t perform that action at this time.