How to Delegate Tezzies (Tezos’ XTZ) with Your Ledger Nano S — With Initial Setup & Screenshots

Awa Sun Yin
Jul 18, 2018 · 8 min read

Updated on: 04.11.2019

Ledger Nano S is one of the most popular hardware wallets in the market. Hardware wallets, also referred as cold wallets or cold storages, are commonly used for securely storing coins, especially large amounts or coins that do not need to be immediately accessible.

Image for post
Image for post
Ledger Nano S with Tezos Wallet Installed

Why spend 79.00€ on a wallet when you can use others for free?

Cryptocurrency holders, who transfer and keep most of their coins in hardware wallets do not only do so because of security. There is also a major benefit, which is the increase of control of your funds, because any exchange could suspend their services or freeze your funds at any time and for undefined periods.

In any case, this article aims to be guideline for setting up your Ledger Nano for receiving XTZ and making delegations to bakers.

Requirements

Before continuing, check that:

  • You have an official Ledger, and bought it from the official store https://www.ledgerwallet.com. Do not use second-hand Ledgers or buy them from unauthorised retailers, as they could’ve been compromised.
  • You have the Ledger Manager installed. Ledger Manager is a Chrome extension. You can find it on Chrome’s Web Store. Check that under the extension name it says offered by www.ledgerwallet.com. There have been extensions or apps that have tried to impersonate the original ones.
Image for post
Image for post
Offered by www.ledgerwallet.com
  • The firmware of your ledger is up-to-date. If you’re updating the firmware now, note that your installed apps will be erased, and you will have to re-install them. Don’t worry, your funds remain, you just have to reinstall the wallets and you’ll have access to them as usual.
  • You have enough space the on device for installing the Tezos Wallet.
  • You have the tezos-client installed. If you don’t, checkout one of my previous articles: How to Deligate Zopf Tezzies (Tezos’ XTZ) with Pâtissière Awa from Cryptium Bäckerei or any other guidelines you prefer.

Setting Up Your Ledger for Tezos

  1. Open the app on your Ledger and you will see on your device’s screen something similar to:
Image for post
Image for post

Your Ledger is now ready. Leave it connected with the Tezos Wallet application open.

Setting Up Your Ledger for Tezos

  1. Run the following command to check the connection:
$ ./tezos-client list connected ledgers→ Disclaimer:
The Tezos network is a new blockchain technology.
Users are solely responsible for any risks associated
with usage of the Tezos network. Users should do their
own research to determine if Tezos is the appropriate
platform for their needs and should apply judgement and
care in their network interactions.
Found a Tezos Wallet 1.1.0 application running on Ledger Nano S at [USB_xxxx_xxxx_xxxxxxxx].Found a Tezos.1.1.0 application running on Ledger Nano S at [USB port]To add the root key of this ledger, use one oftezos-client import secret key ledger_<username>_ed ledger://<tz address> # Ed25519 signaturetezos-client import secret key ledger_<username>_secp ledger://<tz address> # Secp256k1 signatureEach of these tz* is a valid Tezos address.To use a derived address, add a hardened BIP32 path suffix at the end of the URI.[...]In this case, your Tezos address will be a derived tz*.It will be displayed when you do the import, or using command `show ledger path`.

It will detect your Ledger, which generated public and private key sets for different encryption systems based. There’s an extended explanation and recommended read here: (Side note about key generation: https://github.com/obsidiansystems/ledger-app-tezos#importing-the-key-from-the-ledger)

3. Let’s import a secret key. The exact command is listed after you ran the previous step. Just remember to add ./ in front of tezos-client if you’re on MacOS. Obsidian Systems recommends to use the keys generated with curve ed25519. So copy and run the command from your terminal:

$ ./tezos-client import secret key ledger_<username>_ed ledger://<tz address>

Note that ledger_<username>_ed is the name of the account generated with the ed25519 curve, where <username> is the username of your system. E.g. if my username is awa then the generated account would be named ledger_awa_ed. So the previous command would look like:

$ ./tezos-client import secret key ledger_awa_ed ledger://tzadress36charstringadress36charstri

4. After you successfully imported the key, you should see it listed if you run:

$ ./tezos-client list known addresses→ ledger_awa_ed: tzadress36charstringadress36charstri (ledger sk known)

Checking the Balance on Your Ledger-Generated Account

Once you initiated the transaction from the source of the funds, you can check the balance by running the command below.

For the command to work, you should be running your own node in the background (check How to Delegate Tezos XTZ with Tezos Client and Running Your Own Node for instructions on how to run your full node). We recommend that you always run the tezos-client commands with the -A flag:

$ ./tezos-client -A get balance for <accountname or address>

Alternatively, if you’re having issues running your node, you can use our Tezos full node by adding —A mainnet.tezos.cryptium.ch to the command:

$ ./tezos-client -A mainnet.tezos.cryptium.ch get balance for <account name or address>

For example:

$ ./tezos-client -A mainnet.tezos.cryptium.ch get balance for ledger_awa_ed# or$ ./tezos-client -A mainnet.tezos.cryptium.ch get balance for tzaddress36charstringaddress36charstri→ 0.05 ꜩ

How to Delegate and Understanding Implicit and Generated Accounts

a.1) Implicit accounts registered as delegates (bakers): Yes to baking yourself.

a.2) Implicit accounts not registered as delegates (bakers): No to baking.

b) Originated accounts and contracts: Yes to baking, if they have a delegate account set and this baker is actually baking (deligation).

In order to make a delegation, we need to generate a originated account from our implicit account. The account you generated with the Ledger, private key of which you imported into your system, is by default an implicit account. Thus, not suitable for delegation.

To clarify, because Tezos’ documentation is pretty confusing, originated accounts, are actually smart contracts, where the data structure looks like:

Image for post
Image for post

Whenever you generate an originated account you’re actually generating and deploying a smart contract with the fields shown above.

  1. To generate an originated account, run:
/.tezos-client -A mainnet.tezos.cryptium.ch originate account <originated> for <implicit> --delegatable

For example:

/.tezos-client -A mainnet.tezos.cryptium.ch originate account ledger_awa_ed_originated for ledger_awa_ed --delegatable

Remember to add-A mainnet.tezos.cryptium.ch if you’re not running your own node.

With this command, we generated an originated account and transfered 0.05 ꜩ from the implicit account. Note that I named the originated account ledger_awa_ed_originated for convenience, but you could name these accounts as you like.

What’s happening in reality:

Image for post
Image for post

2. Set a baker, you need to add known bakers before you can delegate to them:

$ ./tezos-client -A mainnet.tezos.cryptium.ch add address <bakername> <tzbakeraddress36charstringbakeraddre>

For example, if you wanted to delegate to us, Cryptium Labs Bäckerei, you would run:

$ ./tezos-client -A mainnet.tezos.cryptium.ch add address cryptium_labs_baker tz1eEnQhbwf6trb8Q8mPb2RaPkNk2rN7BKi8

Which sets the delegate in your originated account:

Image for post
Image for post

No matter who you set as a baker, double-, triple-, quadruple-check that the address is the correct one. Else you will be delegating to a different baker. In this case, re-check that the baker address is tz1eEnQhbwf6trb8Q8mPb2RaPkNk2rN7BKi8.

3. Check that the implicit account has been correctly generated:

$ ./tezos-client -A mainnet.tezos.cryptium.ch list known contracts→ ledger_awa_ed_originated: KToriginatedaccount36charstringorigi

4. Finally, let’s delegate:

$ ./tezos-client -A mainnet.tezos.cryptium.ch transfer 0.02 from ledger_awa_ed to ledger_awa_ed_originated --fee 0.0

Note the--fee 0.0 , else you will be paying a default fee of 0.05ꜩ.

After running the command, look at your ledger as it will prompt you to confirm the transaction. Unfortunately, there are no other details than the ones below:

Image for post
Image for post

After confirming, this is what happens to the contract:

Image for post
Image for post

If you just delegated to us, the transaction should be visible very shortly here: https://tzscan.io/tz1eEnQhbwf6trb8Q8mPb2RaPkNk2rN7BKi8

How to Delegate, Everything at Once

  1. First:
$ ./tezos-client -A mainnet.tezos.cryptium.ch add address cryptium_labs_baker tz1eEnQhbwf6trb8Q8mPb2RaPkNk2rN7BKi8

2. And then:

./tezos-client -A mainnet.tezos.cryptium.ch originate account ledger_awa_ed_originated --delegatable for ledger_awa_ed transferring 0.02 from ledger_awa_ed --delegate cryptium_labs_baker --fee 0.0

Remember to double check the baking address and the usernames. Confirm the tx on your Ledger and… voilà!

More How-To Guides

Cryptium Labs

Security-oriented PoS Validator in the Swiss Alps

Awa Sun Yin

Written by

Founder @Cryptium Labs & @MetastateDev

Cryptium Labs

Cryptium Labs offers secure and highly available digital signatures for Proof-of-Stake networks, such as Tezos, Cøsmos, and Polkadot. This blog is dedicated to anyone in the blockchain ecosystem and aims to provide educational content for all audiences on topics such as security.

Awa Sun Yin

Written by

Founder @Cryptium Labs & @MetastateDev

Cryptium Labs

Cryptium Labs offers secure and highly available digital signatures for Proof-of-Stake networks, such as Tezos, Cøsmos, and Polkadot. This blog is dedicated to anyone in the blockchain ecosystem and aims to provide educational content for all audiences on topics such as security.

Medium is an open platform where 170 million readers come to find insightful and dynamic thinking. Here, expert and undiscovered voices alike dive into the heart of any topic and bring new ideas to the surface. Learn more

Follow the writers, publications, and topics that matter to you, and you’ll see them on your homepage and in your inbox. Explore

If you have a story to tell, knowledge to share, or a perspective to offer — welcome home. It’s easy and free to post your thinking on any topic. Write on Medium

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store