Ctez explained.

Cryptonio.tez
Tezos Commons
Published in
7 min readDec 13, 2022

--

It has been just over a year since Ctez was deployed on the mainnet and became a stable building block for the Tezos DeFi ecosystem. I am sure that during this year many of you have heard it being mentioned, but very few actually understand what it is and how it works.

In this article I will try to explain in layman terms what cTez is, why it’s important, how it works, and how to best use it. The sources for the information in this article will be posted at the end.

What is Ctez and Why Do We Need It?

In DeFi, there are a lot of products like decentralized exchanges and lending platforms that pool big amounts of tez from users in their smart contracts and since tez is also used to vote in the governance process of the network, a legitimate question is being brought up: “who is baking all those pooled tez (and therefore who is getting all that voting power)”?

With only two options available:

1. The tez aren’t staked (opportunity cost) and
2. The tez are baked by a specific baker (‘Concentration of power’ risk)

There is a need for a decentralized solution that can eliminate both of those issues. This is where cTez comes in. cTez is a wrapped form of tez that was designed by the co-founder of Tezos Arthur Breitman and deployed by the Plenty team. Its goal is to solve the dilemma mentioned above by maintaining a peg to the tez value including the staking rewards you would be getting over time. This is achieved with the use of mathematics (algorithmically) and as we will see later on it has been working as designed.

It’s worth noting that the smart contracts of cTez are immutable with no admin keys held by anyone, making it a completely decentralized product/tool for the Tezos DeFi ecosystem.

How Does cTez Work?

cTez is minted through ‘personal ovens’ that users can open on the cTez platform. Anyone can open a new oven, deposit tez as collateral, and mint cTez. The tez users put as collateral can be delegated to the baker of their choice and keep earning staking rewards on that tez, which ensures that there is no concentration of voting power.

The amount of cTez users can mint is correlated to the economic mechanisms so let’s take a look at them and various other terms we meet on the cTez platform. If at first read they seem complicated, don’t get disheartened, the farther we progress, the clearer it will all get.

  • Target (price) is the cTez price that the mechanisms of the project are trying to push for. Target is also the metric that dictates the amount of collateral tez that is needed for every cTez minted and although it changes slowly (doesn’t have sudden spikes like the current price), it can cause liquidations of ovens that become under collateralized.
  • Current Price is the actual exchange rate of 1 ctez to tez on the built in cTez Dex (CFMM)
  • Premium is the ratio between the target and the current price of ctez. If the current price is higher than the target then the premium will be positive. If the current price is lower than the target then the premium will be negative
  • Drift is the most important number you need to pay attention to in cTez as it dictates the annual percentage by which the target is changing. The drift changes according to the Premium (when the premium is negative the drift is rising, if the premium is positive the drift is decreasing) and it can be both negative or positive. For example, if the Drift is 5% the target will be rising with a rate of 5% per year, if it is -5% the target will be decreasing by 5% per year.

What we understand from the information above is that for cTez to represent the value of tez along with the staking rewards accurately, the drift needs to float around the staking rewards percentage (at the time of writing ~5.5%).

Remember that drift is dictating the amount by which the target and the actual price is rising. For example, if we start from 1 ctez = 1 tez and we have a drift of 5.5%, after a year the exchange rate will be 1 ctez = 1.055 tez, that means that whether we had been holding 1 tez that we staked or just 1 ctez, we would end up with the same amount of tez and value (1.055 tez).

Source: https://ctez.app/analytics

Looking at the data of the past year we can see that at the start there was a huge spike for Drift (topped at almost 20%) because people didn’t really understand the mechanisms and and kept minting cTez instead of simply buying it from the market even when it wasn’t profitable to do so. Once they figured out how cTez worked the drift started coming back down and for the last few months it has stabilized around the staking rewards percentage just like it was designed to do.

At this point I want to emphasize that minting is not always the right way to get cTez. On the contrary, in most cases just swapping tez to cTez is probably the right way to go.

A simple rule to remember when you need some cTez, is the following:

  • if the Drift percentage is above the staking rewards percentage, it’s better to simply swap tez for cTez (on any of the DEXs),
  • if the drift is lower than the staking rewards, then it makes sense to open an oven and mint cTez (as the staking rewards of your collateral will be more than the appreciation of cTez price).

Another thing worth mentioning that many people seem to misunderstand is that the price of cTez isn’t designed to stay at 1 to 1 with tez, but as we mentioned before, to keep rising at the same rate of the staking rewards you would get if you were holding and staking tez. Note that in some cases and depending on people’s tax situation, just holding ctez might be more convenient or even advantageous than delegating since you dont have to deal with staking rewards when holding cTez.

Source: https://ctez.app/analytics

As we can see on the graph above, the current price of cTez after a year is at 1.10 tez. It started at 1 cTez = 1 tez, but because of the big spike of Drift and the time it took for it to stabilize, it ended up appreciating by ~10% over the year. That means that if someone had swapped his tez to ctez back then and simply held it, he would have outperformed the staking rewards.

Moving forward with the current drift (and if we assumed it would keep floating around the staking rewards percentage) we could predict that the price of cTez in a year would appreciate by another ~5.5% and it would be around 1.16 tez, in two years 1.23 tez, in 5 years 1.44 tez and so on. Of course this “prediction” is more of an example to better explain that cTez is not designed to stay at any fixed price but to keep appreciating in price at a rate similar to the staking rewards.

Quick Recap

  • cTez is a wrapped form of tez designed to be used in DeFi to avoid concentration of power and/or missing on staking rewards
  • cTez can be minted through ovens that use tez as collateral and that can be delegated to the baker of your choice
  • cTez is trying to maintain a peg to tez plus the staking rewards you get over time through some economic mechanisms
  • Premium is the difference between the current price of cTez as seen on the built in DEX (CFMM contract) and the target (price)
  • If Premium is positive, drift starts dropping
  • If Premium is negative, drift starts rising
  • if Drift is positive the target price starts rising
  • if Drift is negative the target price starts dropping
  • If Target price is rising, the collateral utilization of vaults starts rising so the vault owners will eventually need to add more collateral or start paying back cTez that they have minted.
  • If Target price is dropping, the collateral utilization of your vault starts dropping

All the info I shared in this article come from

  1. Arthur’s “Description of cTez mechanisms
  2. The FAQ” of the cTez website and
  3. Conversations in the cTez Telegram group

Since the goal of this article is to give a basic understanding of cTez, I have not included the actual math behind the various metrics and mechanisms. If you are interested for more details and information on cTez, you can check out the sources I posted above.

If you find this article helpful, make sure to subscribe for more!

--

--