Introduction
Hi, I'm cardene, a software engineer and technical writer focused on blockchain and AI.
I've also authored Japanese technical books on specification-driven development with LLMs and decentralized application (DApp) development.
I also build and publish a variety of tools, libraries, and open-source projects.
This article examines ERC-7936, a proposal defining a proxy that supports multiple contract implementation versions and lets users choose which version to use.
The explanation below translates, summarizes, and expands on the original proposal.
I also cover a range of other EIPs, BIPs, SLIPs, CAIPs, ENSIPs, RFCs, and ACPs.
Overview
ERC-7936 introduces explicit version selection to smart contract proxies, which delegate execution to separate implementation contracts. With conventional upgradeable proxies, users typically interact with whichever implementation is currently active. If every user is forced to switch to a new implementation whenever functionality or specifications change, existing applications and external integrations may stop working.
ERC-7936 proposes maintaining a registry within the proxy that associates version identifiers with implementation addresses. Users can select a registered version and execute calls through its corresponding implementation. This allows users to continue using an older version while gradually migrating to newer ones.
Motivation
Smart contracts can remain operational on blockchains for extended periods, making bug fixes and new functionality important. However, many proxy patterns switch all users to the new implementation after an upgrade. This approach has several limitations.
Compatibility problems
Changes to function definitions or data structures in a new implementation can disrupt existing applications and services. When external services depend on an interface that changes, adapting those integrations can require substantial effort.
Limited support for gradual adoption
With conventional proxies, users generally cannot independently choose between the old and new implementations after an upgrade. They cannot simply try a new version while retaining the option of using the old one, which makes gradual migration difficult for risk-sensitive users.
Risks of malicious upgrades
If an administrator or governance body registers a malicious implementation and makes it active, users may be exposed to unexpected behavior or financial losses. ERC-7936 allows users to select and continue using a version they trust, potentially reducing risks associated with automatic migration.
Concentration of trust
Conventional proxies often require users to trust the administrator to perform safe upgrades. If an administrator's private key is compromised or governance is taken over, all users may be affected. ERC-7936 allows users to select an implementation they trust, potentially reducing reliance on the administrator. This benefit depends on the registry's access controls, version removal policies, and the safety of shared storage.
Specification
Interface
interface IVersionedProxy {
/// @notice Emitted when a new implementation version is registered
/// @param version The version identifier
/// @param implementation The address of the implementation contract
event VersionRegistered(bytes32 version, address implementation);
/// @notice Emitted when the default version is changed
/// @param oldVersion The previous default version
/// @param newVersion The new default version
event DefaultVersionChanged(bytes32 oldVersion, bytes32 newVersion);
/// @notice Registers a new implementation version
/// @param version The version identifier (e.g., "1.0.0")
/// @param implementation The address of the implementation contract
function registerVersion(bytes32 version, address implementation) external;
/// @notice Removes a version from the registry
/// @param version The version identifier to remove
function removeVersion(bytes32 version) external;
/// @notice Sets the default version to use when no version is specified
/// @param version The version identifier to set as default
function setDefaultVersion(bytes32 version) external;
/// @notice Gets the implementation address for a specific version
/// @param version The version identifier
/// @return The implementation address for the specified version
function getImplementation(bytes32 version) external view returns (address);
/// @notice Gets the current default version
/// @return The current default version identifier
function getDefaultVersion() external view returns (bytes32);
/// @notice Gets all registered versions
/// @return An array of all registered version identifiers
function getVersions() external view returns (bytes32[] memory);
/// @notice Executes a call to a specific implementation version
/// @param version The version identifier of the implementation to call
/// @param data The calldata to forward to the implementation
/// @return The return data from the implementation call
function executeAtVersion(bytes32 version, bytes calldata data) external payable returns (bytes memory);
}Events
VersionRegistered
event VersionRegistered(bytes32 version, address implementation);An event emitted when a new implementation version is registered. It records the association of an implementation address with a version identifier. Observers can use it to confirm that the registration occurred.
Parameters
version- The version identifier.
implementation- The address of the registered implementation contract.
DefaultVersionChanged
event DefaultVersionChanged(bytes32 oldVersion, bytes32 newVersion);An event emitted when the default version changes. It records a change to the implementation used when no explicit version is specified. This notification is important because the destination of ordinary proxy calls changes.
Parameters
oldVersion- The previous default version.
newVersion- The newly configured default version.
Functions
registerVersion
function registerVersion(bytes32 version, address implementation) external;Registers a new version. It associates a version identifier with an implementation contract address, making the implementation available through the proxy.
Arguments
version- The version identifier to register.
implementation- The address of the implementation contract associated with that version.
removeVersion
function removeVersion(bytes32 version) external;Removes a registered version. The specified version is removed from the registry and is no longer available for subsequent calls through the version-selection interface.
Arguments
version- The version identifier to remove.
setDefaultVersion
function setDefaultVersion(bytes32 version) external;Configures the default version. It determines which implementation handles calls that do not explicitly specify a version. This setting is important for users relying on ordinary proxy behavior.
Arguments
version- The version identifier to configure as the default.
getImplementation
function getImplementation(bytes32 version) external view returns (address);Retrieves the implementation address for a specified version. It returns the implementation contract address associated with the version identifier.
Arguments
version- The version identifier being queried.
Return value
address- The implementation contract address corresponding to the specified version.
getDefaultVersion
function getDefaultVersion() external view returns (bytes32);Retrieves the current default version. It returns the identifier the proxy uses when no version is explicitly selected.
Return value
bytes32- The current default version identifier.
getVersions
function getVersions() external view returns (bytes32[] memory);Retrieves the registered versions. The proxy returns an array containing all registered version identifiers. This allows callers to discover the available versions.
Return value
bytes32[]- An array of registered version identifiers.
executeAtVersion
function executeAtVersion(bytes32 version, bytes calldata data) external payable returns (bytes memory);Executes a call using the implementation associated with a specified version.
The proxy forwards the supplied data to the selected implementation.
It also returns the resulting data, allowing callers to use implementation-specific functionality through the selected version.
Arguments
version- The identifier of the implementation version to execute.
data- The calldata to forward.
Return value
bytes- The raw return data from the implementation call.
Operational requirements
The proxy must satisfy the following requirements.
It maintains a mapping between version identifiers and implementation addresses. It also maintains a default version for calls that do not explicitly specify a version.
When executeAtVersion is called, the proxy checks whether the requested version is registered.
It then forwards execution to the corresponding implementation and returns the resulting data.
Registering a version or changing the default version emits the corresponding event.
Appropriate access controls are recommended for administrative operations, including registering versions, removing versions, and changing the default. Implementations may adopt the EIP-1967 storage slot conventions where appropriate to support compatibility with existing tools.
For more on EIP-1967, see the following article.
[ERC-1967] Understanding Smart Contract Upgrades
Fallback function
The proxy is recommended to implement a fallback function. When a call does not match a function implemented by the proxy itself, the fallback forwards execution to the default implementation. This preserves the conventional proxy interaction model and is important for compatibility with existing users.
Rationale
Why version identifiers use bytes32
ERC-7936 uses bytes32 rather than strings for version identifiers.
First, bytes32 does not prescribe a particular versioning convention, so developers can choose an approach that suits their project.
A semantic version such as 1.0.0 can be encoded into a fixed-length value, or the identifier can represent a numeric version.
Fixed-length values can also require less storage and simpler comparisons than dynamic strings, potentially reducing gas costs. Since proxies may frequently access version information, these savings can be useful.
The type can also accommodate identifiers such as Git commit hashes based on SHA-1 or SHA-256, using their binary representation.
Some development workflows use a particular commit as the version identifier, and bytes32 accommodates that approach.
Explicit version selection
Rather than embedding version information in the implementation calldata, ERC-7936 passes the version explicitly as an argument to executeAtVersion.
This separates the selection of an implementation from the actual function call.
Existing implementation function signatures can remain unchanged. There is no need to embed version-selection logic in each implementation function.
Explicit version selection makes it easier to identify and verify which version was requested by a caller. This improves transparency and can make important operations easier to audit.
Why use a registry?
Several approaches to managing implementation versions are possible, but ERC-7936 selects a registry-based design.
One alternative is to deploy multiple proxies, one for each version. This increases deployment and management overhead. Users would also need to keep track of the correct address for each version, potentially causing confusion.
Another alternative is to store only the latest version. This prevents multiple implementation versions from being used concurrently. One user could not continue using an older version while another experiments with a newer one.
A registry allows several versions to remain accessible at the same time, giving users flexibility to select a version suited to their needs.
The default version mechanism
The default version preserves the interaction model of a conventional proxy.
Even when users do not specify a version, the proxy must know which implementation should handle their calls. Where conventional proxies usually have one active implementation, ERC-7936 explicitly defines a default implementation so that the familiar interaction model remains available.
This accommodates users who only need ordinary proxy functionality while providing explicit version selection to those who require it.
Compatibility
ERC-7936 is designed to preserve the interaction model of existing Ethereum proxies. The fallback function continues forwarding ordinary calls to the default implementation.
Existing contracts and external services that expect conventional proxy calls can therefore continue using the proxy, provided the default implementation maintains the interfaces and behavior they depend on.
Only callers requiring explicit version selection need to use executeAtVersion.
The design aims to expand the flexibility of upgradeable contracts while minimizing disruption to existing integrations.
Citation
Raphina Liu (@Stamp9), Monica Jin (@mokita-j), Martin Monperrus (@monperrus), "ERC-7936: Versioned Proxy Contract Interface [DRAFT]," Ethereum Improvement Proposals, no. 7936, April 2025. [Online serial]. Available: https://eips.ethereum.org/EIPS/eip-7936.
Conclusion
This article covered ERC-7936, a proposal for a versioned proxy that enables callers to select among multiple registered contract implementations.
If you have questions, feel free to reach out via Twitter DM.
I also publish on the following platforms.



