Skip to content
Chainweb: A Proof-of-Work Parallel-Chain Architecture for Massive Throughput
Haskell Other
  1. Haskell 99.5%
  2. Other 0.5%
Branch: master
Clone or download
fosskers Parsing Public Keys (#704)
* Bump stackage LTS

* [miner] Check structural validity of parsed keys

* Remove `Miner` parser
Latest commit 175f54a Nov 14, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github/workflows Add a cabal freeze file (#693) Nov 14, 2019
allocations update allocations generation (#609) Oct 29, 2019
bench Checkpointer benchmarks (#315) Jul 30, 2019
docs Feature Flags (#539) Oct 16, 2019
examples [Transaction Generator] Proper Coin Transfers (#379) Aug 27, 2019
node Tweak error messages (#701) Nov 14, 2019
pact Fix key Nov 4, 2019
rewards Mainnet Allocations (Master) (#607) Oct 29, 2019
scripts Merge branch 'master' into feature/pact-poll Apr 22, 2019
src Parsing Public Keys (#704) Nov 14, 2019
test Consolidate Cut Config (#696) Nov 13, 2019
tools Clean up ChainwebConfiguration (#697) Nov 13, 2019
.gitattributes Add gitattributes to enable github syntax highlighting for hsig files Aug 16, 2018
.gitignore Standalone Executable (#357) Sep 11, 2019
.gitlab-ci.yml Upgrade to GHC 8.6 (#518) Oct 10, 2019 Version bump for release Nov 13, 2019
LICENSE BSD 3 (#70) Mar 26, 2019 Minimal Node Config (#698) [skip ci] Nov 13, 2019
Setup.hs read git info from file Jun 18, 2019
cabal.config Add a cabal freeze file (#693) Nov 14, 2019
cabal.project Bump pact version + keylists -> keysets (#603) Oct 30, 2019
chainweb.cabal Version bump for release Nov 13, 2019
default.nix Upgrade to GHC 8.6 (#518) Oct 10, 2019
docker.nix [nix] Use hash of image's tarball, not its image! Mar 12, 2019 Adding Pact Execution Service future entry to Feb 22, 2019
ghcid Split extra buildInputs off of default.nix and add them to shell.nix.… Nov 28, 2018
minimal-config.yaml Tweak error messages (#701) Nov 14, 2019
overrides.nix Block Misconfigured Peers (#635) Nov 1, 2019
project.nix [Tools] Interactively generate a configuration for chainweb-node. (#680) Nov 9, 2019
shell.nix Fix shell.nix (#548) Oct 18, 2019
stack-nix.yaml add stack-nix-yaml Mar 18, 2019
stack.yaml Parsing Public Keys (#704) Nov 14, 2019
zeus.nix Add zeus.nix Aug 20, 2019



Kadena Public Blockchain

Kadena is a fast, secure, and scalable blockchain using the Chainweb consensus protocol. Chainweb is a braided, parallelized Proof Of Work consensus mechanism that improves throughput and scalability while maintaining the security and integrity found in Bitcoin.

Read our whitepapers:

For additional information, press, and development inquires, please refer to the Kadena website

Table of Contents


The Chainweb wiki serves as a source of information that receives regular updates. You can find the chainweb Wiki here, including a list of frequently asked questions regarding network information, how to explore blocks, diagnosing error messages, and more here.

If you have additions or comments, please submit a pull request or raise an issue.

Installing Chainweb

Linux Users

The binaries can be found here.

Apt-based distributions

If you are on Ubuntu, Debian, CentOS or any other Apt-based distribution, you will need to install rocksdb with the following command:

sudo apt-get update
sudo apt-get install -y librocksdb-dev zlib1g-dev libtinfo-dev libsqlite3-dev libz3-dev z3

If this is not available, then please view the Rocksdb site for alternative modes of installation.

Other distributions

For all other distributions not using Apt (RHEL, Gentoo, Arch, etc), please consult your distro's repositories for librocksdb5.8, tinfo, zlib, z3 and install with its preferred package manager, or follow the alternative modes of installation described in Rocksdb.

At this point, you are ready to run a Chainweb node

Mac Users

Getting the Dependencies

Using the brew package manager, issue the following commands to download Chainweb's dependencies

brew update
brew install z3
brew install sqlite
brew install rocksdb

Building from Source

Chainweb is a Haskell project, and can be built in several ways.

Getting the Code

To get the code, you can go here

You have the code, now let's pick a build tool.

Building with Nix

The fastest way to build and run chainweb is to use the Nix package manager which has binary caching capabilities that allow you to download pre-built binaries for everything needed by Chainweb. For detailed instructions see our wiki.

When the build is finished, you can run chainweb with the following command:

Building with Stack
  • stack >= 1.9
    • Mac (Homebrew): brew install haskell-stack
    • General Linux / Mac

(You may also need to install zlib, openssl, and sqlite.)

Stack is a Haskell build tool that manages compiler and dependency versions for you. It's easy to install and use.

To build a chainweb-node binary:

stack build

This will compile a runnable version of chainweb-node, which you can run via:

stack exec -- chainweb-node

Alternatively, stack install will install the binary to ~/.local/bin/, which you may need to add to your path. Then, you can call chainweb-node as-is.

Building with Cabal
  • ghc >= 8.4 (Haskell compiler) and cabal >= 2.2 (Haskell build-tool)

(You may also need to install zlib, openssl, and sqlite.)

Cabal is the original build tool for Haskell. You will need a version of GHC installed on your machine to use it.

To build a chainweb-node binary:

# Only necessary if you haven't done this recently.
cabal new-update

# Build the project.
cabal new-build

To install a runnable binary to ~/.cabal/bin/:

cabal new-install

Configuring and Running a Chainweb Node

This section assumes you've installed the chainweb-node binary somewhere sensible, or otherwise have a simple way to refer to it.

To configure your node, please use our minimal node configuration. You need to update only one section, hostaddress:

  hostname: your-public-ip-or-domain
  port: 443

Note: You will have to perform Port Forwarding if your machine is behind a router.

Then, to run your node:

chainweb-node --config-file=minimal-config.yaml

Mine for a Chainweb Network

Detailed mining instructions can be found in our Mining Guide.

Chainweb Design

Component Structure

The production components are:

  • chainweb library: It provides the implementation for the different components of a chainweb-node.

  • chainweb-node: An application that runs a Chainweb node. It maintains copies of a number of chains from a given Chainweb instance. It provides interfaces (command-line and RPC) for directly interacting with the Chainweb or for implementing applications such as miners and transaction management tools.

  • chainweb-miner: A stand-alone Mining Client.

  • chainweb-tests: A test suite for the Chainweb library and chainweb-node.

Architecture Overview

For a detailed description of the Kadena architecture, see here.

Architecture Overview

You can’t perform that action at this time.