StarkNet (STRK)
GetBlock provides fast and reliable access to Starknet nodes via JSON-RPC API. Connect to the Starknet network without running your own infrastructure.
Starknet is a permissionless validity (ZK) rollup that settles to Ethereum, executing contracts on the Cairo VM and proving that execution with STARK proofs verified on Ethereum L1. It is not EVM-compatible: contracts are Cairo classes, values are felt252 field elements expressed as hex, and every account is itself a contract under Starknet's native account abstraction. Blocks are addressed by a block_id that is either an object (a block number or block hash) or a tag (latest, pending). The JSON-RPC surface is the standard starknet_* method set: block and state reads, transaction and receipt lookups, contract calls and class/storage reads, event queries, fee estimation, and the invoke/declare/deploy-account write methods.
Key Features
Validity Rollup: Execution is proven with STARK proofs and verified on Ethereum L1, inheriting L1 security
Cairo VM: Contracts are Cairo classes compiled to Sierra, not EVM bytecode; values are felt252 field elements
Native Account Abstraction: Every account is a contract; signature schemes and validation are programmable
block_id Addressing: Reads accept a block number, block hash, or the
latest/pendingtagsDual Fee Tokens: Fees are payable in ETH or STRK; fee amounts carry a unit (
WEIorFRI)Two-Stage Finality: Transactions move from
ACCEPTED_ON_L2toACCEPTED_ON_L1once settled on EthereumClasses and Instances: A class is declared once by hash, then deployed to many contract addresses
Network Information
Network Name
Starknet
Chain ID
0x534e5f4d41494e (SN_MAIN)
Native Fee Tokens
ETH, STRK
Decimals
18
Virtual Machine
Cairo VM (felt252)
Settlement Layer
Ethereum L1 (STARK validity rollup)
Account Model
Native account abstraction
Finality
L1-backed after proof settlement
Base URL
Supported Networks
Mainnet
SN_MAIN
✅
❌
❌
❌
❌
✅
❌
❌
Quickstart
Available API Methods
Chain & Client Info
starknet_specVersion
Version of the Starknet JSON-RPC spec served
starknet_chainId
Chain ID of the connected Starknet network
starknet_syncing
Sync status, or false when fully synced
starknet_blockNumber
Latest accepted block number
starknet_blockHashAndNumber
Latest block hash and number together
Blocks & State
starknet_getBlockWithTxHashes
Block header plus transaction hashes
starknet_getBlockWithTxs
Block header plus full transaction bodies
starknet_getBlockWithReceipts
Block with transactions and their receipts
starknet_getBlockTransactionCount
Number of transactions in a block
starknet_getStateUpdate
State diff applied by a block
Transactions
starknet_getTransactionByHash
Transaction body by hash
starknet_getTransactionByBlockIdAndIndex
Transaction by block and index
starknet_getTransactionStatus
Finality and execution status of a transaction
starknet_getTransactionReceipt
Execution receipt of a transaction
Contracts, Accounts & State
starknet_call
Call a contract view function (no transaction)
starknet_getStorageAt
Raw storage value at a contract key
starknet_getNonce
Account nonce at a block
starknet_getClassHashAt
Class hash deployed at an address
starknet_getClass
Contract class definition by class hash
starknet_getClassAt
Contract class deployed at an address
starknet_getEvents
Filtered events with pagination
Fee Estimation
starknet_estimateFee
Estimate the fee for transactions
starknet_estimateMessageFee
Estimate the fee for an L1-to-L2 message
Write API
starknet_addInvokeTransaction
Submit a signed invoke transaction
starknet_addDeployAccountTransaction
Deploy a new account contract
starknet_addDeclareTransaction
Declare a new contract class
Support
For technical support and questions:
Support: support@getblock.io
See Also
Last updated
Was this helpful?