Changes and updates to Bitcoin have to be tested in a watertight and controlled environment, where if there are errors they do not affect the stability of the main network. This is what is called testnet or test network.
La Testnet The testnet is without a doubt a very useful tool for cryptocurrency developers like Bitcoin. These controlled networks offer a space in which you can make any type of modification without running the risk of everything failing.
The beginnings of the Bitcoin Testnet
The beginnings of the testnet network in Bitcoin date back to 2010, to be more exact to October 19, 2010. At that time, Gavin Andresen send a patch to enable this functionality which was accepted by Satoshi Nakamoto. The patch in question we can see here, and with it starts the first Bitcoin testnet.
With the creation of the first test network, the possibility for developers to test software changes was enabled. without touching the main network. The advantages of these networks are immense, starting with the fact that they allow accelerate software development and expand your evidence base.
However, on February 3, the Testnet1 network would be restarted at the request of developer David François who would raise a patch to the Bitcoin Core code. This new testnet was known as Testnet2. The Testnet2 on the other hand presented two serious problems:
- The network began to have a high difficulty.
- Due to the high difficulty many users took advantage to sell the Testnet coins as real bitcoins.
In this situation, on April 12, 2012, Andresen would restart the network and start the new Bitcoin testnet, the current Testnet3. With this change, Bitcoin developers would ensure that crashes like those of Testnet1 and Testnet2 would not reoccur. Something that in fact they have achieved, since Testnet3 is still active under its own consensus rules.
Mainnet and Testnet What are their differences?
Two networks are associated with Bitcoin, although they are totally separate networks:
- Mainnet: Main network
- Testnet (or Testnet3): Test network
While the bitcoins we know live on the Mainnet network, a cryptocurrency identical to bitcoin "lives" on the Testnet network but with its own type of addresses and its own accounting record or blockchain. We put the word lives in quotation marks, since all that exists is an accounting record. To give you a better idea, look at the following example:
In Testnet the addresses do not start with "1" or "3" as in Bitcoin, but with "m»Or«2«. Examples:
mvN7z3C3GNwTkeEY2tvAQzragtDoiQZ5CF
2NEPMeQcRF7j3uZvQYqsEQxxdCqEnNgDyXd
This difference seems small, but it is what guarantees that it is impossible to send bitcoin from the mainnet to the testnet. This must be so because testnet coins are worthless. The reason is that mining coins on testnet is very simple, so simple that any computer can do it. This obviously does not compare to the difficulty and investment that must be made to achieve the same goal on the Mainnet network.
But if you want to know more about how Bitcoin takes its value, we recommend you read this other article.
Other differences between mainnet and testnet are as follows:
- Testnet uses a different value in the parameter ADDRESS VERSION. This parameter is the one that ends up creating different addresses and that's why no Testnet address works in Bitcoin. While Bitcoin uses 0x00 in Testnet it is used 0x6F. It is key so that they can be visually identified.
- The Testnet network uses a different Genesis block than the main Bitcoin network. The Genesis block is the seed from which the ledger, the blockchain, begins to be created. Only by changing the Genesis block you start a new cryptocurrency, because you start a new ledger.
- Checking IsStandard () written in the Bitcoin code is disabled on Testnet, allowing a perfect setting to experiment with transactions and new ideas.
- In Testnet startup use different seeds of DNS.
- The header of the protocol messages is 0x0B110907 instead of 0xF9BEB4D9 which is used in Bitcoin.
- The Bitcoin program is a node of a P2P network and you need to communicate with other nodes on the network. Normally use the port 8333 from the computer, but in Testnet mode use the port 18333 to be able to operate both modes at the same time on the same computer. A port are points of entry and exit of information that all computers have.
- The Bitcoin program also allows you to communicate with other programs, for example those that you as a developer can create. This is the port used for the protocol RPC. Testnet uses 18332 while Bitcoin uses 8332.
- If a block has not been found within 20 minutes, the difficulty automatically restarts.
We want to help you
FAQs
Find resolved questions about Bitcoin.
Bitcoin was created by Satoshi Nakamoto. The name is a pseudonym and his true identity is unknown. Nakamoto went public with his invention on October 31, 2008, by sending the Bitcoin whitepaper to a mailing list of cryptographers. In 2009 he published the first version of the Bitcoin client and was working on it for a while (along with other developers like Hal Finney) until 2011, when he disappeared and left the project in the hands of others. You can also meet the people most closely linked to the .Satoshi Nakamoto's identity in the article about the usual suspects.
For buy Bitcoins, you must register with a cryptocurrency exchange, such as Bit2Me, and follow the necessary steps to buy Bitcoin using a credit card or bank transfer. You can also expand to know what the detailed steps to buy Bitcoin.
Muchos merchants are beginning to offer the possibility of paying with Bitcoin. In many cases, you will need to have your Bitcoin wallet set up (which will need to contain enough Bitcoin to make the payment), and finally, you will only have to make the payment to the seller's address, indicating how many bitcoins you are going to send. Remember that, if you are going to use this method, you should always check that the address to which you are going to send is correct. You can also pay with Bitcoin using a debit card, such as the Bit2Me Card. In this case, you just have to link the card to your Bitcoin wallet, make sure you have enough funds and pay, just like you would with your usual card.
The Bitcoin price fluctuates constantly due to market fluctuations. You can check the real-time updated quote on different websites, such as CoinMarketCap or TradingView. You also have the possibility to see the graph of its relationship with the Euro in https://pro.bit2me.com/exchange/BTC-EUR.
All the Bitcoin transactionsThey are the transfer of Bitcoins between two Bitcoin addresses. These transactions are recorded on the Bitcoin blockchain, which is an immutable, public ledger. Each transaction is validated by nodes on the Bitcoin network and is confirmed when it is added to a block on the blockchain. Bitcoin transactions are irreversible, which means that once a transaction is confirmed, it cannot be undone. Each transaction has a transaction fee, which is paid to the miners who validate the transaction and add a block to the blockchain.
El Bitcoin (BTC) is the first currency based on asymmetric cryptographyand that has opened up a world of possibilities. The idea of this cryptocurrency stems from other already existing and lesser-known elements, such as HashCash, BitGold or DigiCash, which are combined within a peer-to-peer payment network (peer-to-peer or P2P).
Why was it created and is it so integrated?
Surely the name "Testnet" gives you clues as to why it was created, if not below we leave you the two keys to understand it:
- To improve Bitcoin: It is the perfect setting to analyze the operation of new improvements. It offers a network very similar to Bitcoin, with the same rules and the same way of operating. Before deploying a change in the Mainet version, it is implemented in this network and the result is observed without great consequences.
- To integrate Bitcoin: If you want to create any tool that uses Bitcoin you need to be able to test its transactions and capabilities working with your code, but that code must be fully functional when working with bitcoins.
The main difference between the Bitcoin testing network and the main network is that its coins have no value, since mining them does not entail any considerable cost.
Let's imagine that someone proposes an improvement for Bitcoin. Once this improvement is developed, it must be tested, as it could break Bitcoin, but it cannot be tested on a site that works under a different logic. This enhancement can be run on the Testnet or even a new “Testnet”.
A case of use of the Testnet network we see in SegWit. Without testnet, SegWit testing would have been nearly impossible within the mainnet without causing chaos due to the changes that implementation needed to make.
Testnet coins have no value
Despite being a cryptocurrency almost identical to Bitcoin, as we have explained above (it has 21 million, the block is mined every 10 minutes, ...), this currency It does not have value. It doesn't matter that you have thousands.
This is so because this currency is very easy to get, it has been created so that developers have an environment where they can test things without economic damage.
Tip: Beware of scams! They could try to sell you coins from the Testnet network. You should be very clueless and very new to falling for something like this, but it can happen. Remember how Testnet network addresses start. There you can never receive bitcoins.
Testnet to learn how to use Bitcoin
Testnet is the Bitcoin of newbies.
For what reason?. Well, in it moves a cryptocurrency that does not cost any money and that is given for free but that works with the same rules as Bitcoin. This makes it perfect for the newbie who wants to test how Bitcoin works without actually buying bitcoins. In it, the wallets, the transactions, sending and receiving transactions, everything works in the same way. Visually you will only see that the direction changes.
Many Bitcoin wallets can operate with this network at the push of a button and there are websites (commonly called faucets) that give away the coins.
Imagine that you are a teacher and you want your students to experiment or that you want to have your first experience. Although you could jump in the mud and do it with real money, you can also do it on Testnet.
You should just follow these steps:
- Go to the purse Bit2Me Wallet, which has support for the Bitcoin testing network.
- Once opened press the button "+" for “Create new wallet”.
- Give the wallet a name in this case “Bitcoin Testnet” and select the network “Bitcoin Testnet”.
- Press the button "Create Wallet".
- Once created, you can click on the "Receive" button and copy the address that it shows you.
- You access a Testnet faucet, for example this, and enter the copied address (At the end of the post you have a few more faucets).
- In a few seconds or minutes you will receive your Testnet coins in your wallet.
- Once you have them you can send them to other Testnet addresses.
This can be a great experience, which does not take more than 15 minutes, to have direct contact without the need for bitcoins with the technology and potential of Bitcoin.
Mining
As we have said, the coins of the test network are given away, that is: the complexity of mining on the Bitcoin testnet is ridiculous. With an old computer you can mine per CPU non-stop, with an extra cost of almost zero light.
Testnet is designed to have a very low complexity, however, in each block and as it happens in Bitcoin, it is increasing.
This means that the complexity could rise so much that no one would mine, since they are coins that have no value. To solve this, in Testnet3 a feature was added designed so that when a block cannot be mined due to its complexity, it automatically goes to very low levels. That is, it "restarts" the complexity.
Blockchain size
As we have stated, Testnet has its own accounting record, blockchain. But this record doesn't have the frenzy of Bitcoin's activity. While Bitcoin Blockchain now exceeds 260 GBThat of Testnet barely exceeds 23 GB.
And what happens when the chain takes up a lot? Well, a blockchain with many gigabytes could also make its maintenance intangible if there are no incentives. The funny thing is that before taking a relevant size, the coins to be issued are finished. As you can see, the 21 million limit is about to be issued, something that is expected in Bitcoin by the year 2140.
Almost 21 million coins issued in just 4 or 5 years? It seems somewhat strange, because if for each block a number of coins are released under the same Bitcoin rules and we said that the Bitcoin testnet has the same mining logic as the mainnet, it should also take about 120 years, 10 minutes on average per block.
The reason for this is due to Testnet3's previously discussed functionality: When complexity increases it restarts, and allows many blocks to be mined in less time, reducing the average time per block by much.
That is, while in Bitcoin it can take around 1000 minutes to mine 100 blocks, Testnet takes much less, maybe between 100 and 200 minutes (it is only an estimate looking at the charts)
And what happens if all 21 million are issued? Possibly a new Testnet, 4, will be agreed. The objective is to have no value so that coins are constantly being generated that allow testing to improve Bitcoin and its ecosystem.
Get started on Bit2Me and jump into the world of cryptocurrencies with a head start. Sign up easily and get €5 FREE on your first purchase with this link. Don't wait any longer to join the crypto revolution! Register
RegTest, testing regressions in Bitcoin
The Bitcoin Core software also has the default configuration of an even more unknown network (despite being defined in your documentation), the RegTest (regression test) call, which can also be started with a parameter on the command line.
> bitcoind -regtest -daemon Bitcoin server starting
It was added to the Bitcoin Core 0.9.0 version, which was released in March 2014, and was created as an alternative testing mode.
This network can be used to create Blockchains with the same characteristics as Testnet but only between nodes that we want. That is, with this mode we can create private blockchains that operate under our control.
Some developers think that it is one of the perfect ways to start creating new functionalities and doing research with Blockchain technology, all under a 100% controlled environment.
Ressources
Finally, we want to share with you a private collection of the resources that, from Bit2Me, we consider most important and that you will need whatever your objective.
Faucets Testnet (Free Coins)
- https://bitcoinfaucet.uo1.net/
- https://tpfaucet.appspot.com/
- https://kuttler.eu/en/bitcoin/btc/faucet/
- https://coinfaucet.eu/en/
Blockchain Explorer Testnet
Testnet compatible wallets
- Bit2Me Wallet
- Copay (Multiplatform)
- mycellium (Android)
- Bitcoin Wallet (Android)
Testnet Compatible API Services
Click here to open your user account in Spanish for FREE and securely and receive a €5 gift.