<p>Besides allowing range of network addresses for clients, you need to add also specify <code>rcpbind=server_ip_address</code> for the server (where your bitcoin core is running).</p>
<p>The default value for <code>rcpbind</code> is <code>127.0.0.0</code> and it only allows RPC to listen on the <code>localhost</code> and not on <code>0.0.0.0</code>.</p>
<p>In order to have the ability to connect from localhost <em>and</em> from the network add the setting twice, as shown in <a href="https://sparrowwallet.com/docs/connect-node.html" rel="nofollow noreferrer">example</a>:</p>
<pre><code>server=1
rpcuser=bitcoin
rpcpassword=yourpassword

[main]
rpcbind=127.0.0.1
rpcbind=192.168.0.10
rpcallowip=127.0.0.1
rpcallowip=192.168.0.0/16
</code></pre>
<p>EDIT:
Alternatively, instead of typing the specific address of the server, you can just use <code>rcpbind=0.0.0.0</code> to force RPC to listen on <code>0.0.0.0</code>. This is more flexible, but then you rely solely on <code>rpcallowip</code> to allow only local connections.</p>

CC BY-SA 4.0
2022-03-29T20:31:42.160Z
2022-03-29T21:06:27.450Z
2022-03-29T21:06:27.450Z
Radzor
<p>Two thoughts:</p>

<ol>
<li><p>The wildcard syntax is not supported anymore. Instead of <code>192.168.*.*</code>, use <code>192.168.0.0/16</code>. Instead of <code>192.168.1.*</code>, use <code>192.168.1.0/24</code>.</p></li>
<li><p>As an additional debugging step, try running <code>netstat -antlp | grep 8332</code>. If that produces output like the following, that means that it <em>is</em> bound to the port.</p>

<pre><code>tcp        0      0 0.0.0.0:8332             0.0.0.0:*               LISTEN 
</code></pre></li>
</ol>

CC BY-SA 3.0
2018-01-09T19:04:17.317Z
Thanks. After `netstat`it turns out my bitcoin node listen at port 18332, not 8332.
Ozgur
CC BY-SA 4.0
2019-08-25T09:13:10.737Z
Did you ever figure out why it doesn't use the provided port?
ulu
CC BY-SA 4.0
2023-10-24T05:16:43.250Z
Where can I find actual official documentation for bitcoin.conf?
gkucmierz
CC BY-SA 4.0
2023-10-24T15:51:40.487Z
@gkucmierz You should ask that as a question so that it's easily searchable.
Nick ODell
CC BY-SA 3.0
2015-12-20T03:08:15.380Z
2015-12-20T19:01:12.910Z
2015-12-20T19:01:12.910Z
Nick ODell
<p>I have read a similar post which had no answer <a href="https://bitcoin.stackexchange.com/questions/4949/why-isnt-bitcoind-listening-on-its-rpc-port" title="at this location.">at this location</a>. I am trying to use bitcoin-cli from a host that different from the host that runs bitcoind.  I also would be happy with being able to use curl to issue rpc requests.  I have had much success with getting bitcoind and bitcoin-cli to communicate within the same host, but activating the rpc port for external communication has proven to be beyond difficult if not impossible, and I am seeking your help.</p>

<p>I have started bitcoind with the following configuration file:</p>

<pre><code>server=1
rpcuser=jared
rpcpassword=1234
rpcport=8332
rpcallow=192.168.*.*
gen=0
prune=600
</code></pre>

<p>(Note, the password will be changed after the system is working)</p>

<p>I have confirmed that the system is functioning on the local machine using bitcoin-cli to get the following:</p>

<pre><code>{
    "version" : 110200,
    "protocolversion" : 70002,
    "blocks" : 183745,
    "timeoffset" : -1,
    "connections" : 8,
    "proxy" : "",
    "difficulty" : 1583177.84744401,
    "testnet" : false,
    "paytxfee" : 0.00000000,
    "relayfee" : 0.00005000,
    "errors" : ""
}
</code></pre>

<p>And from another host on the network, I have used nmap to scan the ports to display:</p>

<pre><code>Starting Nmap 6.47 ( http://nmap.org ) at 2015-12-19 15:20 PST
Nmap scan report for c161.attlocal.net (192.168.1.68)
Host is up (0.0014s latency).
Not shown: 997 closed ports
PORT     STATE SERVICE
22/tcp   open  ssh
80/tcp   open  http
8333/tcp open  unknown
</code></pre>

<p>In the question referenced above, the user was able to cause the rpc port to open by removing the rpcallow lines from his configuration file. He commented them out, and the problem fixed itself. I have also tried this and not had any luck.</p>

<p>I also have tried using rpcallow of '192.168.1.*', '192.168.0.0/16', '192.168.1.0/24' and once tried using rpcbind, which appears to be related to an older version of bitcoind as it is no longer listed in the man pages for bitcoin.conf.</p>

<p>My system is running the following OS:</p>

<pre><code>Distributor ID: Ubuntu
Description:    Ubuntu 15.10
Release:    15.10
Codename:   wily
</code></pre>

<p>Any and all help is appreciated!  Kind regards, and thank you.</p>

CC BY-SA 3.0
2015-12-20T00:25:42.573Z
The wildcard syntax is not supported anymore, you need to use 192.168.0.0/16. What does `netstat -antlp | grep 8332` say?
Nick ODell
CC BY-SA 3.0
2015-12-20T01:31:44.347Z
@NickODell, please add your comment as an answer so I can give you credit for solving my problem.  The RPC port does not display as an open port on nmap even still, but it is clear the bitcoin-cli application is communicating with the primary host.
Jared Clemence
<bitcoind><json-rpc><ubuntu><bitcoin-cli>
Why is my bitcoind daemon not listening on RPC port at 8332?
Jared Clemence
# Why is my bitcoind daemon not listening on RPC port at 8332?

(Asked by: username_0 on 2015-12-19)

I have read a similar post which had no answer [at this location](https://bitcoin.stackexchange.com/questions/4949/why-isnt-bitcoind-listening-on-its-rpc-port "at this location."). I am trying to use bitcoin-cli from a host that different from the host that runs bitcoind. I also would be happy with being able to use curl to issue rpc requests. I have had much success with getting bitcoind and bitcoin-cli to communicate within the same host, but activating the rpc port for external communication has proven to be beyond difficult if not impossible, and I am seeking your help.

I have started bitcoind with the following configuration file:

```
server=1
rpcuser=username_0
rpcpassword=1234
rpcport=8332
rpcallow=192.168.*.*
gen=0
prune=600

```

(Note, the password will be changed after the system is working)

I have confirmed that the system is functioning on the local machine using bitcoin-cli to get the following:

```
{
    "version" : 110200,
    "protocolversion" : 70002,
    "blocks" : 183745,
    "timeoffset" : -1,
    "connections" : 8,
    "proxy" : "",
    "difficulty" : 1583177.84744401,
    "testnet" : false,
    "paytxfee" : 0.00000000,
    "relayfee" : 0.00005000,
    "errors" : ""
}

```

And from another host on the network, I have used nmap to scan the ports to display:

```
Starting Nmap 6.47 ( http://nmap.org ) at 2015-12-19 15:20 PST
Nmap scan report for c161.attlocal.net (192.168.1.68)
Host is up (0.0014s latency).
Not shown: 997 closed ports
PORT     STATE SERVICE
22/tcp   open  ssh
80/tcp   open  http
8333/tcp open  unknown

```

In the question referenced above, the user was able to cause the rpc port to open by removing the rpcallow lines from his configuration file. He commented them out, and the problem fixed itself. I have also tried this and not had any luck.

I also have tried using rpcallow of '192.168.1.\*', '192.168.0.0/16', '192.168.1.0/24' and once tried using rpcbind, which appears to be related to an older version of bitcoind as it is no longer listed in the man pages for bitcoin.conf.

My system is running the following OS:

```
Distributor ID: Ubuntu
Description:    Ubuntu 15.10
Release:    15.10
Codename:   wily

```

Any and all help is appreciated! Kind regards, and thank you.

**Tags:** bitcoind, json-rpc, ubuntu, bitcoin-cli

> **Comments:**
> **username_1**: The wildcard syntax is not supported anymore, you need to use 192.168.0.0/16. What does `netstat -antlp | grep 8332` say?  
> **username_0**: @username_1, please add your comment as an answer so I can give you credit for solving my problem.  The RPC port does not display as an open port on nmap even still, but it is clear the bitcoin-cli application is communicating with the primary host.  

---

## 2 answers

### Answer by username_1 on 2015-12-20. Score: 5 | Accepted answer

Two thoughts:

1. The wildcard syntax is not supported anymore. Instead of `192.168.*.*`, use `192.168.0.0/16`. Instead of `192.168.1.*`, use `192.168.1.0/24`.
2. As an additional debugging step, try running `netstat -antlp | grep 8332`. If that produces output like the following, that means that it *is* bound to the port.

   ```
   tcp        0      0 0.0.0.0:8332             0.0.0.0:*               LISTEN 

   ```

> **Comments:**
> **username_3**: Thanks. After `netstat`it turns out my bitcoin node listen at port 18332, not 8332.  
> **username_4**: Did you ever figure out why it doesn't use the provided port?  
> **username_5**: Where can I find actual official documentation for bitcoin.conf?  
> **username_1**: @username_5 You should ask that as a question so that it's easily searchable.  

---

### Answer by username_2 on 2022-03-29. Score: 0

Besides allowing range of network addresses for clients, you need to add also specify `rcpbind=server_ip_address` for the server (where your bitcoin core is running).

The default value for `rcpbind` is `127.0.0.0` and it only allows RPC to listen on the `localhost` and not on `0.0.0.0`.

In order to have the ability to connect from localhost *and* from the network add the setting twice, as shown in [example](https://sparrowwallet.com/docs/connect-node.html):

```
server=1
rpcuser=bitcoin
rpcpassword=yourpassword

[main]
rpcbind=127.0.0.1
rpcbind=192.168.0.10
rpcallowip=127.0.0.1
rpcallowip=192.168.0.0/16

```

EDIT:
Alternatively, instead of typing the specific address of the server, you can just use `rcpbind=0.0.0.0` to force RPC to listen on `0.0.0.0`. This is more flexible, but then you rely solely on `rpcallowip` to allow only local connections.


---

