<p>A quick update if you are still having this issue then please use this command now</p>
<pre><code>cardano-cli query tip --testnet-magic 1
</code></pre>
<p>as testnet arguments have been changed. you can use both 1 and 2 based on your network preview or preprod.</p>

CC BY-SA 4.0
2022-11-29T11:21:54.213Z
2022-11-29T11:21:54.213Z
Muhammad Usman
<p>The testnet magic, aka protocol magic, is a parameter introduced in Cardano during the Byron era. It is used internally by the protocol in cryptographic functions that construct addresses from a seed. Since this value is different in mainnet and testnet, the address obtained from a given path (or seed) is different in both networks.</p>

CC BY-SA 4.0
2021-09-16T18:11:46.680Z
But why is 1097911063? Are there other testnets with different number?
Boommeister
CC BY-SA 4.0
2021-09-18T02:15:04.383Z
@G-Unit It's just an identifier, it could have been any other unique number, but I don't know why they chose that specific number. Other testnets used different numbers (I've seen the number 42, for instance)
vaz
CC BY-SA 4.0
2021-12-22T20:42:11.853Z
Possible answer which explains a little bit more about this - https://stackoverflow.com/q/67191023/1336068
Bharat Mallapur
CC BY-SA 4.0
2021-09-03T20:35:45.973Z
2021-09-03T20:35:45.973Z
vaz
<p>I am currently running a testnet-node version 1.29.0.<br/>
To query the blockain, I use the command <code>cardano-cli query tip --testnet-magic 1097911063</code> to get the last block.</p>
<p>What is the testnet-magic argument and why is it 1097911063?</p>
<hr />
<p>I got the command from <a href="https://developers.cardano.org/docs/get-started/running-cardano" rel="noreferrer">https://developers.cardano.org/docs/get-started/running-cardano</a></p>

<cardano-cli><testnet><query>
What is the testnet-magic argument and why is it 1097911063?
# What is the testnet-magic argument and why is it 1097911063?

(Asked by: username_0 on 2021-09-03)

I am currently running a testnet-node version 1.29.0.  
To query the blockain, I use the command `cardano-cli query tip --testnet-magic 1097911063` to get the last block.

What is the testnet-magic argument and why is it 1097911063?

---

I got the command from <https://developers.cardano.org/docs/get-started/running-cardano>

**Tags:** cardano-cli, testnet, query

---

## 2 answers

### Answer by username_2 on 2021-09-03. Score: 12 | Accepted answer

The testnet magic, aka protocol magic, is a parameter introduced in Cardano during the Byron era. It is used internally by the protocol in cryptographic functions that construct addresses from a seed. Since this value is different in mainnet and testnet, the address obtained from a given path (or seed) is different in both networks.

> **Comments:**
> **username_3**: But why is 1097911063? Are there other testnets with different number?  
> **username_2**: @G-Unit It's just an identifier, it could have been any other unique number, but I don't know why they chose that specific number. Other testnets used different numbers (I've seen the number 42, for instance)  
> **username_4**: Possible answer which explains a little bit more about this - https://stackoverflow.com/q/67191023/1336068  

---

### Answer by username_1 on 2022-11-29. Score: -1

A quick update if you are still having this issue then please use this command now
cardano-cli query tip --testnet-magic 1

as testnet arguments have been changed. you can use both 1 and 2 based on your network preview or preprod.


---

