<p>The argument for <code>getbalance</code> is not an address. It is for an account, which is not the same as an address. To get the entire wallet balance, do <code>getbalance</code> with no arguments.</p>

CC BY-SA 3.0
2017-11-24T10:38:14.733Z
@ Andrew the getbalance with no arguments is for the entire wallet.But how can I chech the balance for a particular public key/address?
gtopal
CC BY-SA 3.0
2017-11-24T18:37:45.020Z
You can't. You have to add that address to an account (aka give it a label). Then you can use getbalance to get the balance of that account, and if it only has one address, it will be the balance of that address.
Ava Chow
CC BY-SA 3.0
2017-11-27T11:56:26.190Z
now make sense!
gtopal
CC BY-SA 3.0
2018-04-26T23:25:51.120Z
use bitcoind -regtest -txindex and bitcoin-tx
cmc
CC BY-SA 3.0
2017-11-22T14:32:27.377Z
2017-11-22T14:32:27.377Z
Ava Chow
<p>I have created a regtest address and I want to check it's balance.</p>

<p>I have run the commands:</p>

<ol>
<li>-regtest generate 101</li>
<li>-regtest getbalance</li>
<li>-regtest sendtoaddress n4MN27Lk7Yh3pwfjCiAbRXtRVjs4Uk67fG 10.00</li>
<li>-regtest generate 6</li>
<li>-regtest getbalance n4MN27Lk7Yh3pwfjCiAbRXtRVjs4Uk67fG </li>
</ol>

<p>after the 5th step the balance is still 0.</p>

<p>Why this happened since I have already sent 10 BTC to my address?
Do I have to sign any outputs in order to claim the bitcoins?</p>

<p><a href="https://i.sstatic.net/yoLwB.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/yoLwB.png" alt="enter image description here"></a></p>

<bitcoin-core><address><regtest>
How to check my address balance in regtest?
gtopal
# How to check my address balance in regtest?

(Asked by: username_0 on 2017-11-22)

I have created a regtest address and I want to check it's balance.

I have run the commands:

1. -regtest generate 101
2. -regtest getbalance
3. -regtest sendtoaddress n4MN27Lk7Yh3pwfjCiAbRXtRVjs4Uk67fG 10.00
4. -regtest generate 6
5. -regtest getbalance n4MN27Lk7Yh3pwfjCiAbRXtRVjs4Uk67fG

after the 5th step the balance is still 0.

Why this happened since I have already sent 10 BTC to my address?
Do I have to sign any outputs in order to claim the bitcoins?

[![enter image description here](https://i.sstatic.net/yoLwB.png)](https://i.sstatic.net/yoLwB.png)

**Tags:** bitcoin-core, address, regtest


---

## 1 answers

### Answer by username_1 on 2017-11-22. Score: 2 | Accepted answer

The argument for `getbalance` is not an address. It is for an account, which is not the same as an address. To get the entire wallet balance, do `getbalance` with no arguments.

> **Comments:**
> **username_0**: @ Andrew the getbalance with no arguments is for the entire wallet.But how can I chech the balance for a particular public key/address?  
> **username_1**: You can't. You have to add that address to an account (aka give it a label). Then you can use getbalance to get the balance of that account, and if it only has one address, it will be the balance of that address.  
> **username_0**: now make sense!  
> **username_2**: use bitcoind -regtest -txindex and bitcoin-tx  

---

