Are you a developer working on a Bitcoin project or are you a power user discovering the more advanced Bitcoin features? This post explains how to get started with the Bitcoin testnet so you can play without using your real, hard-earned coins.
None of the Bitcoin client applications implement all of those features, (yet) so you'll have to use the Bitcoin RPC interface from the command line.
Download and install the Bitcoin Core client (previously named Bitcoin-Qt). You can, but don't have to, start the application. It will start downloading the huge, real blockchain, which you don't need for testing.
- Find the Bitcoin Core data directory for your system.
Create this directory if it doesn't exist yet (should be there from when you ran the client before). On Mac OS X for example:
mkdir ~/Library/Application\ Support/Bitcoin/
bitcoin.confconfiguration file in that directory. A minimal example might look like:
Start the Bitcoin Core client. The application icon should be green instead of orange. The green icon indicates it's running in testnet mode. The client will start downloading the testnet blockchain and this will take a while.
While you wait for the testnet blockchain to download, you can grab some testnet coins. Find a Bitcoin testnet faucet and send yourself some coins (you can find an address in the Bitcoin Core client).
The coins will only show up in the Bitcoin Core client application when the blockchain download has caught up, so wait for it to finish.
Time to try it out. Here is a simple cURL command to ask the Bitcoin daemon for some general info using a JSON RPC: