Reading the code, I see that transactions can contain an unlimited number of tx_extra_field items.

tx_extra_field is defined in src/cryptonote_core/tx_extra.h as a union of a few possible types, identified by a type byte:

#define TX_EXTRA_TAG_PADDING                0x00
#define TX_EXTRA_TAG_PUBKEY                 0x01
#define TX_EXTRA_NONCE                      0x02
#define TX_EXTRA_MERGE_MINING_TAG           0x03

Further, nonces can be one of:

#define TX_EXTRA_NONCE_PAYMENT_ID           0x00

What are each of these types/formats used for? Also, what is the purpose of padding?


1 Answer 1


Padding is for adding freeform data of arbitrary length. It can be used to embed any data, for example a human readable mesage.

Pubkey is for the transaction public key (R in the Cryptonote whitepaper).

Nonce is for extra data, currently only used for the payment ID. Classic style payment IDs are 256 bits and unencrypted, while integrated address payment IDs are 64 bits and encrypted.

Merge mining tag is meant to be used for merge mining. Only Fantomcoin can be merged mined to my knowledge.

Minergate's tag's use is unknown. Minergate started using it a few months ago.

  • How is it possible to use tx-extra with monero-wallet-cli ?
    – datazone
    Commented Apr 22, 2021 at 13:23
  • 1
    There's no tooling for arbitrary use, and it's discouraged anyway since it distinguishes transactions, thereby allowing spies purchase to try and violate people's privacy.
    – user36303
    Commented Apr 23, 2021 at 9:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.