Skip to content
This new developer portal is under construction. For complete documentation, please refer to the old developer portal.

Participation Key Management

Algorand provides a set of keys for voting and proposing blocks separate from account spending keys. These are called participation keys (sometimes referred to as partkeys). At a high-level, participation keys are a specialized set of keys located on a single node. Once this participation key set is associated with an account, the account has the ability to participate in consensus.

Read more about how Participation Keys function in the Algorand Consensus Protocol.

Generating Participation Keys With NodeKit

To generate your participation key with NodeKit, you can use our comprehensive guide that you can find here:

Generating Participation Keys With goal

To generate a participation key, use the goal account addpartkey command on the node where the participation key will reside. This command takes the address of the participating account, a range of rounds, and an optional key dilution parameter. It then generates a VRF key pair and, using optimizations, generates a set of single-round voting keys for each round of the range specified. The VRF private key is what is passed into the VRF to determine if you are selected to propose or vote on a block in any given round.

$ goal account addpartkey -a <address-of-participating-account> --roundFirstValid=<partkey-first-round> --roundLastValid=<partkey-last-round>
Participation key generation successful

This creates a participation key on the node. You can use the -o flag to specify a different location in the case where you will eventually transfer your key to a different node to construct the keyreg transaction.

Add Participation Key

If you chose to save the participation key and now want to add it to the server, you can use the following command to add the partkey file to the node.

$ goal account installpartkey --partkey ALICE...VWXYZ.0.30000.partkey --delete-input

Check that the Key Exists

The goal account listpartkeys command will check for any participation keys that live on the node and display pertinent information about them.

$ goal account listpartkeys
Registered Account ParticipationID Last Used First round Last round
yes TUQ4...NLQQ GOWHR456... 27 0 3000000

The output above is an example of goal account listpartkeys run from a particular node. It displays all partkeys and whether or not each key has been registered, the filename of the participation key, the first and last rounds of validity for the partkey, the parent address (i.e. the address of the participating account) and the first key. The first key refers to the key batch and the index in that batch (<key-batch>.<index>) of the latest key that has not been deleted. This is useful in verifying that your node is participating (i.e. the batch should continue to increment as keys are deleted). It can also help ensure that you don’t store extra copies of registered participation keys that have past round keys intact.

View Participation Key Info

Use goal account partkeyinfo to dump all the information about each participation key that lives on the node. This information is used to generate the online key registration transaction described in the next section.

$ goal account partkeyinfo
Dumping participation key info from /opt/data...
Participation ID: GOWHR456IK3LPU5KIJ66CRDLZM55MYV2OGNW7QTZYF5RNZEVS33A
Parent address: TUQ4HOIR3G5Z3BZUN2W2XTWVJ3AUUME4OKLINJFAGKBO4Y76L4UT5WNLQQ
Last vote round: 11
Last block proposal round: 12
Effective first round: 1
Effective last round: 3000000
First round: 0
Last round: 3000000
Key dilution: 10000
Selection key: l6MsaTt7AiCAdG+69LG/wjaprsI1vImZuGN6gQ1jS88=
Voting key: Rleu99r3UqlwuuhaxCTrTQUuq1C9qk5uJd2WQQEG+6U=

Above is the example output from a particular node. Use these values to create the key registration transaction that will place the account online.

Renew Participation Keys

The process of renewing a participation key is simply creating a new participation key and registering it online before the previous key expires.

You can renew a participation key anytime before it expires, and we recommend to do it at least two weeks (about 268,800 rounds) in advance so as not to risk having an account marked as online that is not participating.

The validity ranges of participation keys can overlap. For any account, at any time, at most one participation key is registered, namely the one included in the latest online key registration transaction for this account.

Step-by-Step

Example Key Rotation Window
Example key rotation window

Removing Old Keys

When a participation key is no longer in use, you can remove it by running the following goal command with the participation ID of the key you want to remove.

$ goal account deletepartkey --partkeyid IWBP2447JQIT54XWOZ7XKWOBVITS2AEIBOEZXDACX5Q6DZ4Z7VHA

Make sure to identify the correct key (i.e. make sure it is not the currently registered key) before deleting.