<p>If you want to send some coins, you have to have been given some coins before. </p>

<p>When someone sends coins to you, they make a new transaction. This transaction has a TxID (which is the double SHA256 hash of the raw transaction bytes) that everyone uses to refer to this transaction. A transaction can have multiple outputs, and each outputs allocates some of the previously unspent transaction outputs (UTXO) that were used as inputs in the new transaction. </p>

<p><img src="https://i.sstatic.net/WvyLE.png" alt="Diagram transaction inputs and outputs"></p>

<p>So, really this question comes down to: what are bitcoins? Bitcoins are a pair of TxID and an index that uniquely specify an entry in the blockchain.</p>

<p>The developer documentation (<a href="https://bitcoin.org/en/developer-documentation" rel="nofollow noreferrer">https://bitcoin.org/en/developer-documentation</a>) goes into great detail if you want to learn more.  </p>

<p>As far as how do you actually get your hands on these values, you just have to have someone send you coins to your address (or mine them), and then you could just look your address up on a blockchain explorer and find any unspent outputs it has. From there, you can just use the web interface to see the txid and the output index. For example, I just grabbed a random transaction off from blockchain.info at <a href="https://blockchain.info/tx/86e06fed6f597dc212e72556a84660d84e9536e081719624a0a30a685238d0d7" rel="nofollow noreferrer">https://blockchain.info/tx/86e06fed6f597dc212e72556a84660d84e9536e081719624a0a30a685238d0d7</a>. You can see the txid is 86e06fed6f597dc212e72556a84660d84e9536e081719624a0a30a685238d0d7 and that there are two outputs (indices 0 and 1), the first of which has been spent, and the second one which has not been spent (at the time of writing).</p>

CC BY-SA 3.0
2014-12-03T14:22:45.157Z
But how do I get Txin thats the real mystery
tor
CC BY-SA 3.0
2014-12-03T14:26:58.347Z
Txin/vout is just the index of the previous transaction output that you are spending. So in the example I gave, Txin/vout is 0 or 1, depending on which ouptut you are trying to spend.
morsecoder
CC BY-SA 3.0
2014-12-04T16:53:36.280Z
So how do I get it?
tor
CC BY-SA 3.0
2014-12-04T17:17:07.200Z
Find the transaction that was sent to an address that you own on a block explorer, such as blockchain.info, and look at which output has your address in it. The first output has txin/vout 0, the second has txin/vout 1, etc...
morsecoder
CC BY-SA 4.0
2018-07-28T02:47:51.590Z
How do I find the transaction id (txid) with  a address by local bitcoin node, the address maybe not inside my wallet?
Frank AK
CC BY-SA 4.0
2022-11-10T09:22:31.723Z
@FrankAK some wallets supports the RPC call "getaddressutxos" 
Returns all unspent outputs for an address (requires addressindex to be enabled).
Dick Larsson
CC BY-SA 3.0
2014-12-03T04:49:55.693Z
2014-12-03T05:10:03.020Z
2014-12-03T05:10:03.020Z
morsecoder
<p>I was in the <a href="http://coinb.in/multisig/#newTransaction" rel="noreferrer">http://coinb.in/multisig/#newTransaction</a> and wanted to make a input but it needed 2 values.</p>

<ol>
<li>Txid, How do I get that?</li>
<li>TxIn/vout, Whats that and how do I get that?</li>
</ol>

<transactions><multi-signature><raw-transaction>
How do I find the txid and vout values for an input I want to spend?
tor
# How do I find the txid and vout values for an input I want to spend?

(Asked by: username_0 on 2014-11-28)

I was in the <http://coinb.in/multisig/#newTransaction> and wanted to make a input but it needed 2 values.

1. Txid, How do I get that?
2. TxIn/vout, Whats that and how do I get that?

**Tags:** transactions, multi-signature, raw-transaction


---

## 1 answers

### Answer by username_1 on 2014-12-03. Score: 3 | Accepted answer

If you want to send some coins, you have to have been given some coins before.

When someone sends coins to you, they make a new transaction. This transaction has a TxID (which is the double SHA256 hash of the raw transaction bytes) that everyone uses to refer to this transaction. A transaction can have multiple outputs, and each outputs allocates some of the previously unspent transaction outputs (UTXO) that were used as inputs in the new transaction.

![Diagram transaction inputs and outputs](https://i.sstatic.net/WvyLE.png)

So, really this question comes down to: what are bitcoins? Bitcoins are a pair of TxID and an index that uniquely specify an entry in the blockchain.

The developer documentation (<https://bitcoin.org/en/developer-documentation>) goes into great detail if you want to learn more.

As far as how do you actually get your hands on these values, you just have to have someone send you coins to your address (or mine them), and then you could just look your address up on a blockchain explorer and find any unspent outputs it has. From there, you can just use the web interface to see the txid and the output index. For example, I just grabbed a random transaction off from blockchain.info at <https://blockchain.info/tx/86e06fed6f597dc212e72556a84660d84e9536e081719624a0a30a685238d0d7>. You can see the txid is 86e06fed6f597dc212e72556a84660d84e9536e081719624a0a30a685238d0d7 and that there are two outputs (indices 0 and 1), the first of which has been spent, and the second one which has not been spent (at the time of writing).

> **Comments:**
> **username_0**: But how do I get Txin thats the real mystery  
> **username_1**: Txin/vout is just the index of the previous transaction output that you are spending. So in the example I gave, Txin/vout is 0 or 1, depending on which ouptut you are trying to spend.  
> **username_0**: So how do I get it?  
> **username_1**: Find the transaction that was sent to an address that you own on a block explorer, such as blockchain.info, and look at which output has your address in it. The first output has txin/vout 0, the second has txin/vout 1, etc...  
> **username_2**: How do I find the transaction id (txid) with  a address by local bitcoin node, the address maybe not inside my wallet?  
> **username_3**: @username_2 some wallets supports the RPC call "getaddressutxos"  Returns all unspent outputs for an address (requires addressindex to be enabled).  

---

