Skip to main content
Transfers SOL (in lamports) between Solana accounts.
This method returns a SolanaInstruction. Add it to a transaction and use the Transaction Service to execute it on-chain. See Instructions & Transactions.

Transfer

Transfers SOL (in lamports) from one account to another.

Request

Base58-encoded public key (string)
required
The sender account. Must be a signer.
Base58-encoded public key (string)
required
The recipient account.
uint64
required
Amount of SOL to transfer, in lamports. 1 SOL = 1,000,000,000 lamports.

Response

SolanaInstruction (object)
The System Program transfer instruction. Add to a transaction via CompileTransaction.

Code Examples


TransferWithSeed

Transfers SOL from a seed-derived account. The sending account’s address is derived from a base public key and seed, so the base key (not the derived address) signs the transaction.

Request

Base58-encoded public key (string)
required
The seed-derived sender account address.
Base58-encoded public key (string)
required
Base public key used to derive from. This account must be a signer.
string
required
Seed string used to derive from.
Base58-encoded public key (string)
required
The recipient account.
uint64
required
Amount to transfer, in lamports. 1 SOL = 1,000,000,000 lamports.

Response

SolanaInstruction (object)
The System Program transfer_with_seed instruction. Add to a transaction via CompileTransaction.

Code Examples