How to Backup, Store, and Sync Your Secret Token Viewing Keys

Secret Network
Secret Network Ecosystem
5 min readSep 15, 2022

--

Secret Token viewing keys give you granular control over who gets to see your financial data by acting as passwords that allow you and trusted third parties to view your assets.

This tutorial will take you through how to back up your viewing keys and manage them across multiple devices.

What we’ll cover in this guide:

💡 Want to know more about Secret Tokens and viewing keys? Check out our Secret Tokens Learn page.

Why back up your Secret Token viewing keys

It’s easy to create new viewing keys for your Secret Tokens, so losing yours isn’t a huge deal. However, you might want to back up your Secret Token viewing keys for various other reasons:

  • To share with others so they can more easily access your funds in case you lose access
  • To sync your Secret Tokens across multiple devices
  • To avoid having to create new viewing keys if you accidentally delete yours, and having to re-sync any devices

That’s why this tutorial will take you through various methods to back up your viewing keys.

Note: Your viewing keys are already automatically stored in any wallet you use to hold your Secret Tokens.

💡 Want to know how to create viewing keys for your Secret Tokens? Check out our tutorial.

How to store and share your viewing keys

The good news is that your viewing keys falling into the wrong hands isn’t disastrous. Even with your viewing key, someone won’t be able to see your funds without your public wallet address, and won’t be able to control your funds without your private key.

That being said, we don’t want to become completely careless, so here are a few general best practices we recommend:

  • Store your viewing keys locally rather than in the cloud. You can simply store the CSV file that many viewing key tools like CryptoClerk provide
  • Don’t store your viewing keys along with your wallet information like your public key, private key, or seed phrase
  • When you want to share viewing keys, use secure communication methods like i2p and Proton

To make life easier for yourself, store your viewing keys along with the corresponding Secret Token contract addresses so you can easily import your viewing keys on another device.

💡 Read our How to Stay Safe in DeFi guide for more ways to protect your assets.

How to back up your viewing keys

There are two ways to back up your viewing keys:

  1. You can use Enigma’s Wizard Tool to copy/export multiple viewing keys at the same time
  2. You can use the Keplr token list and copy your viewing keys one by one

We’ll go through both of these methods.

Method #1: Backup using the Wizard Tool

The Wizard Tool is a nifty tool developed by the dev team behind Secret Network, SCRT Labs, and allows you to export and save multiple viewing keys at once.

🔔 Note: Right now the app says “This app is broken until the next Keplr version comes out”, but this refers to the viewing key creation function, nót the backup function! (luckily for us)

  • Navigate to Enigma’s Wizard Tool and connect your wallet
  • Click on “Export tokens from Keplr to CSV” — Keplr will prompt you to store the viewing keys locally on your device as an Excel document

Now you should have a CSV overview of your Secret Tokens and viewing keys which you can share locally on your device!

Method #2: Manual back up with the Keplr Token List

If you don’t want to use an external app and you have a Keplr wallet, you can also copy and back up your viewing keys manually.

Here are the steps:

  • Open your Keplr browser extension — make sure you selected “Secret Network” at the top
  • Click on the menu in the top left corner
  • Select “Token List”
  • Click the “copy” icon next to a Secret Token to copy the viewing key to your clipboard and paste it into your backup file of choice

How to manage your viewing keys on multiple devices

Because creating a new viewing key for a specific Secret Token deprecates the old one, you can’t create a viewing key on each device you want to access your Secret Tokens on, as it’d render the viewing keys on your other device useless.

Instead, you must port over the viewing key you created on one device to the other, so they’re synced. Here’s how to do so:

Step 1: Get your viewing keys from your first device

  • Login to your Keplr wallet with the device you’ve used to create your viewing keys
  • Use either the Wizard Tool or the Keplr Token List to gather all your active viewing keys (see the “Back up” section to find out how)

Step 2: Look up your Secret Token smart contract addresses

  • Navigate to the Secret Analytics website
  • Click on “Snip” in the left-side menu
  • Scroll down until you see the Tokens interface, then copy the smart contract addresses of your Secret Tokens (e.g. SSCRT)

Step 3: Add the viewing keys on your second device

  • Open your Keplr wallet extension in your browser on your second device
  • Click on the menu in the top left corner
  • Select “Add Token”
  • Paste the smart contract address of the Secret Token you want to add into the “Contract Address” field
  • Tick the “(Advanced) Import my own viewing key” box and insert the corresponding viewing key
  • Click “Submit”

If everything went alright, you’ll now see your Secret Tokens show up in your Keplr wallet!

Repeat these steps for all your Secret Tokens and make sure to repeat them when you generate a new viewing key, on whatever device. You can use this process to sync any number of wallets on different devices.

That’s it! Now you know how to manage and back up your Secret Tokens, allowing you to take full advantage of their benefits.

Want to know more about Secret Tokens, Secret DeFi, and how to make use of Secret’s privacy-preserving apps? We have more content in the works — follow us on Twitter or here on Medium to stay in the loop!

--

--

Secret Network
Secret Network Ecosystem

The Data Privacy Platform For Web3 — build and use blockchain applications that are both permissionless and privacy-preserving.