Ethereum Function Selector

Compute the 4-byte function selector and event topic (keccak256) from a Solidity signature — in your browser.

🔒 100% in your browser — nothing is uploaded

Use canonical types with no spaces or argument names — e.g. transfer(address,uint256).

How it works

Enter a function or event signature like transfer(address,uint256) to get its 4-byte selector (the first 4 bytes of keccak256, used to route contract calls) and its full keccak256 hash (the event topic). Use canonical types with no spaces or argument names. Runs entirely in your browser.

Frequently asked questions

What is a function selector?

The first 4 bytes of keccak256 of a function signature. Contract calldata starts with this selector so the contract knows which function you are calling.

How do I write the signature?

Use the canonical form: the function name plus parameter types in parentheses, no spaces and no argument names — e.g. transfer(address,uint256).

What is the event topic?

The full 32-byte keccak256 of an event signature (topic0), used to filter logs for that event.

Related tools

Embed this tool

Add this free tool to your own site: