Skip to content
ERC1155 lets one contract manage many token types, fungible and non-fungible, and move several of them in one call. On Solana, each token type is a mint under the Token Program, and one transaction can transfer any number of them.

​What ERC1155 defines

An ERC1155 contract stores balances by token ID and owner. One ID can be a currency with a large supply, and another can be a unique item. safeBatchTransferFrom moves several IDs at once, which saves gas compared with one ERC20 or ERC721 call per token.

ERC1155: One contract, many token IDs

  • Balances live in a nested mapping of ID and owner.
  • An ID is fungible or unique, depending on its supply.
  • Batch functions move several IDs in one call.

Solana: One program, one mint per ID

  • Each token type is a mint under the Token Program.
  • The supply and decimals of the mint decide whether it is fungible.
  • One transaction carries a transfer instruction for each mint.

​Token IDs become mints

Create one mint for each ERC1155 token ID. Every mint uses the same Token Program, so adding a token type is a transaction and needs no deployment. If you have not read the ERC20 guide, it explains mints and token accounts.
Three ERC1155 token IDs as three mints.Three ERC1155 token IDs as three mints.

Three ERC1155 token IDs as three mints.

ERC1155 token typeSolana mint
Fungible ID, such as a currencyA mint with decimals and a large supply
Semi-fungible ID, such as a stackable itemA mint with 0 decimals and a supply above 1
Non-fungible IDA mint with 0 decimals and a supply of 1, or a Metaplex Core asset

​ERC1155 functions on Solana

Replace the token ID argument with the mint address.
ERC1155SolanaHow it maps
balanceOf(owner, id)Token account amountRead the owner’s associated token account for that mint.
balanceOfBatch()Several account readsFetch several token accounts in one RPC call with getMultipleAccounts.
safeTransferFrom()TransferCheckedTransfer between the two owners’ token accounts for the mint. Solana has no receiver callback, so verify the recipient address yourself.
safeBatchTransferFrom()Several instructionsAdd one transfer instruction per mint to the same transaction.
setApprovalForAll()No equivalentApprove a delegate per token account. No operator covers every token a wallet holds.
uri(id)Metadata uriEach mint has its own metadata with a name, symbol, and URI.

​Batch transfers

A batch transfer is a list of transfer instructions in one transaction. They run in order and atomically: if one fails, none of them applies.
Watch the transaction sizeEach transfer adds a source account, a destination account, and a mint to the transaction. A legacy or v0 transaction holds 1,232 bytes, and a v1 transaction holds 4,096 bytes. Split a very large batch across transactions. In a v0 transaction, you can also use an address lookup table, which stores addresses onchain so that the transaction references them by index.

​Collections and metadata

An ERC1155 contract address groups its token IDs. On Solana, mints are independent, so you link them with metadata:

​Next steps