<p>Electrum doesn't connect directly to Bitcoin nodes. Instead it connects to Electrum servers using the Electrum protocol. These servers run Bitcoin nodes and additional Electrum server software in order to provide the data that Electrum actually needs to operate. So you need to be running an Electrum server software that connects to your node and then connect Electrum to that Electrum server.</p>
<p>Some Electrum server software:</p>
<ul>
<li><a href="https://github.com/chris-belcher/electrum-personal-server" rel="nofollow noreferrer">Electrum Personal Server</a>: EPS is designed for use with a single Electrum wallet and is probably the easiest to get an Electrum wallet connected to a full node</li>
<li><a href="https://github.com/shesek/bwt#electrum-plugin" rel="nofollow noreferrer">Bitcoin Wallet Tracker with Electrum plugin</a>: BWT is like EPS but does more stuff and isn't just limited to Electrum</li>
<li><a href="https://github.com/spesmilo/electrumx/" rel="nofollow noreferrer">ElectrumX</a>: ElectrumX is the official Electrum server software. It is a full fledged Electrum server software that is intended to be used by any connecting Electrum wallet. As such, it indexes the entire blockchain. If you want to do experimentation with the Electrum protocol, you may want to use this.</li>
<li><a href="https://github.com/romanz/electrs" rel="nofollow noreferrer">Electrs</a>: Like ElectrumX but written in Rust.</li>
</ul>

CC BY-SA 4.0
2020-08-10T15:59:50.533Z
Hi, Andrew, thanks for the clarification. I'm able to run `electrum --testnet` and connect to testnet network (receive funds from faucets, send money to other address, etc) without setting up any of the servers you've mentioned. So, why do I need EPS or ElectrumX when running `electrum --regtest`? Sounds like a wired design hack.
Cartucho
CC BY-SA 4.0
2020-08-10T16:24:57.090Z
@Cartucho Testnet is a public test network. There are people who run Electrum servers on testnet in the same way that people run Electrum servers on mainnet. When you use testnet, you are connecting to those public testnet servers. However regtest is a private testing network. This means you need to setup all of the relevant infrastructure yourself.
Ava Chow
CC BY-SA 4.0
2020-08-10T15:51:39.020Z
2020-08-10T15:51:39.020Z
Ava Chow
<p><strong>The problem</strong></p>
<ul>
<li>I have a regtest network running in <code>127.0.0.1:18443</code>.</li>
<li>I can access to regtest with <code>user:123</code>.</li>
<li>I would like to use Electrum (v4.0.2) with my local regtest but I cannot realize how to do that.</li>
</ul>
<p><strong>What I tried</strong></p>
<p>When I run:</p>
<pre><code>electrum --regtest
</code></pre>
<p>The Electrum console opens as expected but the status is not connected:</p>
<p><a href="https://i.sstatic.net/hNulf.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/hNulf.png" alt="enter image description here" /></a></p>
<p>My <code>~/.electrum/regtest</code> contains:</p>
<pre><code>{
    &quot;auto_connect&quot;: false,
    &quot;blockchain_preferred_block&quot;: {
        &quot;hash&quot;: &quot;0f9188f13cb7b2c71f2a335e3a4...........a11466e2206&quot;,
        &quot;height&quot;: 0
    },
    &quot;check_updates&quot;: false,
    &quot;config_version&quot;: 3,
    &quot;dont_show_testnet_warning&quot;: true,
    &quot;gui_last_wallet&quot;: &quot;/home/xxx/.electrum/regtest/wallets/default_wallet&quot;,
    &quot;is_maximized&quot;: false,
    &quot;oneserver&quot;: false,
    &quot;recently_open&quot;: [
        &quot;/home/xxx/.electrum/regtest/wallets/default_wallet&quot;
    ],
    &quot;rpcpassword&quot;: &quot;123&quot;,
    &quot;rpcuser&quot;: &quot;user&quot;,
    &quot;server&quot;: &quot;127.0.0.1:18443:s&quot;,
    &quot;show_addresses_tab&quot;: true
}

</code></pre>
<p>I changed <code>rpcpassword</code> and <code>rpcuser</code> with the user:pass of my local regtest, but I'm still unable to connect Electrum with my local network.</p>
<p><strong>My questions</strong></p>
<ul>
<li>What am I doing wrong?</li>
<li>What does the &quot;s&quot; mean in <code>127.0.0.1:18443:s</code>?</li>
<li>What's running in <code>127.0.0.1:51002</code>?</li>
</ul>

CC BY-SA 4.0
2020-08-10T15:49:34.290Z
@Prayank Interesting, I'll take a look.
Cartucho
<electrum><regtest>
How to use Electrum with a local regtest network?
Cartucho
# How to use Electrum with a local regtest network?

(Asked by: username_0 on 2020-08-10)

**The problem**

* I have a regtest network running in `127.0.0.1:18443`.
* I can access to regtest with `user:123`.
* I would like to use Electrum (v4.0.2) with my local regtest but I cannot realize how to do that.

**What I tried**

When I run:

```
electrum --regtest

```

The Electrum console opens as expected but the status is not connected:

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

My `~/.electrum/regtest` contains:

```
{
    "auto_connect": false,
    "blockchain_preferred_block": {
        "hash": "0f9188f13cb7b2c71f2a335e3a4...........a11466e2206",
        "height": 0
    },
    "check_updates": false,
    "config_version": 3,
    "dont_show_testnet_warning": true,
    "gui_last_wallet": "/home/xxx/.electrum/regtest/wallets/default_wallet",
    "is_maximized": false,
    "oneserver": false,
    "recently_open": [
        "/home/xxx/.electrum/regtest/wallets/default_wallet"
    ],
    "rpcpassword": "123",
    "rpcuser": "user",
    "server": "127.0.0.1:18443:s",
    "show_addresses_tab": true
}

```

I changed `rpcpassword` and `rpcuser` with the user:pass of my local regtest, but I'm still unable to connect Electrum with my local network.

**My questions**

* What am I doing wrong?
* What does the "s" mean in `127.0.0.1:18443:s`?
* What's running in `127.0.0.1:51002`?

**Tags:** electrum, regtest

> **Comments:**
> **username_0**: @Prayank Interesting, I'll take a look.  

---

## 1 answers

### Answer by username_1 on 2020-08-10. Score: 4 | Accepted answer

Electrum doesn't connect directly to Bitcoin nodes. Instead it connects to Electrum servers using the Electrum protocol. These servers run Bitcoin nodes and additional Electrum server software in order to provide the data that Electrum actually needs to operate. So you need to be running an Electrum server software that connects to your node and then connect Electrum to that Electrum server.

Some Electrum server software:

* [Electrum Personal Server](https://github.com/chris-belcher/electrum-personal-server): EPS is designed for use with a single Electrum wallet and is probably the easiest to get an Electrum wallet connected to a full node
* [Bitcoin Wallet Tracker with Electrum plugin](https://github.com/shesek/bwt#electrum-plugin): BWT is like EPS but does more stuff and isn't just limited to Electrum
* [ElectrumX](https://github.com/spesmilo/electrumx/): ElectrumX is the official Electrum server software. It is a full fledged Electrum server software that is intended to be used by any connecting Electrum wallet. As such, it indexes the entire blockchain. If you want to do experimentation with the Electrum protocol, you may want to use this.
* [Electrs](https://github.com/romanz/electrs): Like ElectrumX but written in Rust.

> **Comments:**
> **username_0**: Hi, Andrew, thanks for the clarification. I'm able to run `electrum --testnet` and connect to testnet network (receive funds from faucets, send money to other address, etc) without setting up any of the servers you've mentioned. So, why do I need EPS or ElectrumX when running `electrum --regtest`? Sounds like a wired design hack.  
> **username_1**: @username_0 Testnet is a public test network. There are people who run Electrum servers on testnet in the same way that people run Electrum servers on mainnet. When you use testnet, you are connecting to those public testnet servers. However regtest is a private testing network. This means you need to setup all of the relevant infrastructure yourself.  

---

