As we get closer to launch, people are starting to get their affairs in order to begin baking on Tezos. However, there are still a lot of unknowns (especially for those that aren’t close to the Riot chat and development communities). This is a very simplified Tezos baking guide to help people understand how baking works and what is involved in being a baker.

Firstly, lets start off with a few definitions:

Baking — the Delegated Proof of Stake consensus mechanism used by Tezos. That means that the next “person” that can add a block to the chain is decided based on the amount of total stake they control. Delegation — if a user does not wish to (or can’t) participate in the baking process, they can delegate their staking power to someone else. Baker — someone who participates in the baking process. Also known as a “delegate (noun)”. Staker — the term we use for someone who is delegating their stake to someone else. Staking Power — is the sum of a bakers available balance, all stake being delegated, and all frozen bonds. This is used to decide how often a baker can bake. Cycles and Levels — the level is essentially the block number (genesis being 0) — cycles occur every 4096 levels/blocks.

Baking setup — How do I get started?

Firstly, you need to register to bake — this is a simple operation that can be done via the CLI wallet, and should be available in most other wallets and baking software.

You also need to ensure that you have at least 1 roll of tez (10,000ꜩ), and you must run baking software 24/7. This requires a computer and an internet connection that is fairly stable. The process isn’t resource consuming (like POW), so an old, basic device should be fine.

Once you are setup as a baker, you need to wait until you have the right to bake before you can actually start baking.

Baking rights — What are rights and how do I get them?

A bakers’ right to bake is sort of like a waiting room— for a given block X you may be 10th in the waiting line to bake. Everyone is given a time based on their position in the line, and if that time passes and block X hasn’t been baked, then you may attempt to bake that block.

Usually, the first in line will bake the block, but there are some circumstances where this may not actually happen (allowing for some great steals).

On the surface, baking rights are calculated based on a bakers “staking power”. However there are a few very important points to keep in mind:

Rights are “backdated” in a sense — the protocol uses your staking power from approximately 7 cycles prior. That’s about 20 days (depending on the network speed). This is called the “rights cycle” — e.g. the rights cycle used for cycle 10 is cycle 3. A random snapshot that occurred during the rights cycle is used (to prevent people from gaming the baking process and moving large amounts of ꜩ to improve their apparent stake. i.e. if the snapshot used was always the start of the cycle, you could see users buy XTZ right before to increase their staking power and sell it shortly after).

This means that if you register to bake today, and ensure you have at least 10,000ꜩ, you wont actually be able to start baking for about 20 days.

Interestingly — this also means that after you have emptied your baking wallet, you will still have rights to bake for another 7 cycles.

Baking Deposits — I now have rights, what now?

Once you have the right to bake, your baking software should handle the rest and attempt to bake the block for you. This incurs a security deposit, which for baking is 512ꜩ.

It is very important to remember the following — the bond can only be paid from the bakers available balance. A staker’s balance can not be used to cover bonds.

These security deposits/bonds become frozen, and deducted from the bakers available balance. You should only lose the deposit if you intentionally do something malicious (e.g. double bake/endorse).

Baking software should prevent this from occurring — the idea is to provide a disincentive for malicious activity by enforcing a large cost (losing the bond).

Deposits, if not lost, are returned with the block reward approximately 6 cycles later (about 17 days)**.

Baking Rewards — Show me the money!

As mentioned, rewards for a given cycle X are paid 6 cycles later — 16ꜩ is the reward for baking a block (plus the fees for the operations included in that block).

Based on the protocol variables, theoretically 8.25% of a users staking power will be frozen as bonds at any given time. So a baker with 10,000ꜩ baking (and no delegated stake) should expect about 825ꜩ to be frozen as bonds.

However, if the baker’s balance is 10,000ꜩ, but they have 90,000ꜩ in delegated stake, than the total staking power is 100,000ꜩ. In this scenario, you would expect roughly 8,250ꜩ of the bakers balance to be frozen (that works out to be 82.5% of the bakers balance in this scenario). This means the baker will only have an available balance of 1,750ꜩ to spend or use for future bonds.

What about endorsing?

Endorsing works the same way, and is calculated in a similar fashion (which is why I didn’t include it in the guide above). Most of the time your baking software will also handle endorsements too. Here are the differences:

There are 32 endorsements per block The security deposit is only 64ꜩ per endorsement A single baker may have multiple endorsements per block The reward is significantly less (approximately 2ꜩ, but in some cases it can be lower) You get no share of the operation fees included in a given block

Summary

Something that I think people need to be aware of is how their XTZ balance will look when they first start baking. Here’s a quick scenario — you obtain your genesis allocation, register your baker and begin to bake within the first few days of the network launch. You need to keep in mind the following:

You won’t actually begin baking for approx. 20 days, so you could get away with not running your baking software for a few weeks (i.e. if you are still in the setup stage — just register right away, and take the time to get your systems ready) Once you start baking, your balance will slowly decrease as bonds are taken out of your account. Don’t get scared and move your funds into cold-storage if you see your balance begin to drop. You won’t see any rewards for approx. 17 days after you start baking, that means after you first register to bake, you won’t see any rewards for approx. 37 days.

So there you have it, a guide on baking and a few tips that I hope will help people understand the inner workings of it all. Keep a look out for some upcoming articles about baking with BakeChain, and being a staker and delegating your stake. If you have any questions, please shoot us a line and we’d be happy to help!

**Actually, rewards are paid out at the end of the cycle 5 times later, which is effectively 6 cycles later so we use that to simplify things.