Free 30-min Web3 Consultation
Book Now
Smart Contract Security Audits
Learn More
Custom DeFi Protocol Development
Explore
Full-Stack Web3 dApp Development
View Services
Free 30-min Web3 Consultation
Book Now
Smart Contract Security Audits
Learn More
Custom DeFi Protocol Development
Explore
Full-Stack Web3 dApp Development
View Services
Free 30-min Web3 Consultation
Book Now
Smart Contract Security Audits
Learn More
Custom DeFi Protocol Development
Explore
Full-Stack Web3 dApp Development
View Services
Free 30-min Web3 Consultation
Book Now
Smart Contract Security Audits
Learn More
Custom DeFi Protocol Development
Explore
Full-Stack Web3 dApp Development
View Services
LABS
Guides

How to Approve Upgrade Proposals

A technical guide for developers on participating in blockchain governance to vote on and approve protocol upgrades, including Ethereum Improvement Proposals (EIPs), Solana BPF upgrades, and Cosmos governance proposals.
Chainscore © 2026
introduction
GOVERNANCE

How to Approve Upgrade Proposals

A step-by-step guide for token holders to participate in on-chain governance by voting on and executing protocol upgrades.

On-chain governance allows token holders to directly influence a protocol's future by voting on upgrade proposals. These proposals can modify core parameters, add new features, or deploy entirely new smart contract logic. The process typically involves three phases: a temperature check or forum discussion, a formal on-chain vote, and finally, a timelock execution. This guide focuses on the critical final step: approving and executing a successful proposal. Major protocols like Uniswap, Compound, and Aave use variations of this model, often built on frameworks like OpenZeppelin Governor.

Before a proposal can be executed, it must pass a governance vote. Voters cast their tokens, with voting power usually proportional to their stake. A proposal passes if it meets a predefined quorum (minimum participation) and achieves a majority vote (e.g., >50% for, or a 4% supermajority for critical changes). Once passed, the proposal enters a timelock period—a mandatory delay (often 2-7 days) that gives users time to react to upcoming changes or exit the system if they disagree. This is a crucial security feature.

To execute the upgrade, the approved proposal's encoded calldata must be submitted to the governance contract's execute function. This transaction can be submitted by any address, but typically requires the proposer or a designated executor to pay the gas fee. The execution will fail if attempted before the timelock expires or if the underlying transaction logic reverts. Always verify the proposal's status and hash on the protocol's official interface (like Tally or the project's own dashboard) before proceeding.

Here is a simplified example of executing a proposal using ethers.js, assuming you have the proposal ID and the Governor contract address. This code checks the state and calls the execute function.

javascript
const { ethers } = require('ethers');
const provider = new ethers.providers.JsonRpcProvider('RPC_URL');
const wallet = new ethers.Wallet('PRIVATE_KEY', provider);

const governorAddress = '0x...';
const proposalId = '123...';

const governorABI = [
  'function state(uint256 proposalId) view returns (uint8)',
  'function execute(uint256 proposalId)'
];
const governor = new ethers.Contract(governorAddress, governorABI, wallet);

async function executeProposal() {
  // 1. Check proposal state (4 = Queued, ready for execution)
  const state = await governor.state(proposalId);
  if (state !== 4) {
    throw new Error(`Proposal not executable. State: ${state}`);
  }
  // 2. Execute the proposal
  const tx = await governor.execute(proposalId);
  await tx.wait();
  console.log(`Proposal ${proposalId} executed in tx: ${tx.hash}`);
}

Security is paramount when interacting with governance. Always verify the proposal hash against the original discussion to ensure you are executing the correct, unaltered code. Be wary of malicious proposals disguised as upgrades. Use a hardware wallet for the transaction if possible. After execution, monitor the protocol for the intended changes and any unexpected behavior. Failed executions can sometimes be retried, but this depends on the specific governance implementation and the reason for failure.

Participating in proposal execution is a key responsibility for engaged governance members. It finalizes the community's decision and activates new protocol functionality. By understanding the steps—from verifying vote success and timelock expiry to submitting the execute transaction—you contribute directly to the protocol's evolution and security. For specific parameters like quorum, voting period, and timelock duration, always consult the protocol's latest documentation, as these can differ significantly between implementations.

prerequisites
PREREQUISITES

How to Approve Upgrade Proposals

Before you can participate in on-chain governance by approving a proposal, you must meet specific technical and procedural requirements. This guide outlines the essential setup.

To approve a governance proposal, you must first hold the protocol's native governance token. For example, to vote on a Uniswap upgrade, you need UNI tokens; for Compound, you need COMP. The tokens must be self-custodied in a wallet you control, such as MetaMask, WalletConnect, or a hardware wallet. Tokens held on a centralized exchange (CEX) like Coinbase are not eligible for voting, as you do not control the private keys required to sign the transaction.

Your wallet must be connected to the correct blockchain network. Most DAOs operate on Ethereum mainnet, but many have deployed governance contracts on Layer 2 solutions like Arbitrum or Optimism to reduce gas costs. Ensure your wallet is configured for the appropriate network. You will also need a small amount of the network's native cryptocurrency (e.g., ETH for Ethereum mainnet) to pay for the gas fee required to submit your approval transaction.

You need to understand the proposal's voting period and quorum requirements. Proposals are typically live for a fixed number of blocks (e.g., 3-7 days). Your vote must be cast within this window. Furthermore, most DAOs require a minimum participation threshold, or quorum, for a proposal to pass. Before voting, check the DAO's documentation or interface to confirm the current proposal state and deadlines.

Familiarize yourself with the governance interface. Most protocols use a dedicated front-end like Tally, Snapshot, or a custom dashboard (e.g., Compound Governance). You will use this interface to connect your wallet, review the proposal details—including the target contract address and executable calldata—and cast your vote. Always verify you are on the official website to avoid phishing scams.

For technical delegates or those voting via smart contract, you may need to interact directly with the governance contract. This requires the contract's ABI and address, which can be found in the protocol's documentation. You can use libraries like ethers.js or web3.py to call the castVote function, providing the proposal ID and your support (usually 1 for for, 0 against). Ensure your script or dApp handles transaction signing and gas estimation correctly.

Finally, consider the delegation mechanism. If you do not wish to vote directly, you can delegate your voting power to a trusted address or delegate. This is often a one-time transaction that authorizes another wallet to vote on your behalf. If you have previously delegated, you must either vote with the delegate's key or revoke delegation before you can submit a personal vote.

key-concepts-text
GOVERNANCE IN ACTION

How to Approve Protocol Upgrade Proposals

A technical guide for token holders on evaluating, voting, and executing on-chain protocol upgrades in decentralized networks.

Protocol upgrades are the mechanism by which decentralized networks evolve. Unlike traditional software, changes to a blockchain's core logic—its smart contracts, consensus rules, or economic parameters—require collective approval from its stakeholders. This process is formalized through on-chain governance, where token holders submit, debate, and vote on upgrade proposals. A successful vote does not automatically change the code; it authorizes a specific transaction that executes the upgrade, moving the protocol from one state to the next. Understanding this flow from proposal to execution is critical for participants in networks like Compound, Uniswap, Arbitrum, and Optimism.

Before casting a vote, a holder must conduct due diligence. This involves analyzing the proposal payload, which is typically the calldata for a function that will be called on a privileged contract (like a Timelock or Governor). You should verify the target contract address, the function signature (e.g., upgradeTo(address)), and the arguments. For complex upgrades, the proposal will point to an external document, such as a Snapshot space or a forum post, detailing the technical specifications, audit reports, and risk assessments. Key questions to ask include: What bug fixes or features does this enable? Has the new contract code been audited? What are the failure modes if the upgrade has an error?

Voting is executed by calling a function on the governance contract. For example, in a Compound-style GovernorBravo system, you would call the castVote(uint proposalId, uint8 support) function. The support parameter is an integer where 1 = for, 0 = against, and 2 = abstain. Your voting power is typically determined by your token balance at the block when the proposal was created (a snapshot). Votes are usually cast directly from your wallet using a block explorer's write function, a dedicated UI like Tally, or by interacting with the contract via a script. Always confirm the correct proposalId and that the proposal is in the active voting state.

Once a proposal passes its vote and any mandatory timelock delay expires, it moves to the queue and then execute state. The timelock is a critical security feature that gives users time to exit the system if they disagree with the upgrade. Execution is the final, irreversible step. Anyone can call the execute function on the governance contract, which triggers the previously approved transaction. For a proxy upgrade using the Transparent Proxy Pattern or UUPS, this executes a call to the proxy admin contract to change its implementation address. After execution, the new logic is immediately active. Monitor post-upgrade for any unexpected behavior, as a faulty upgrade may require an emergency proposal to revert.

UPGRADE MECHANISMS

Governance Model Comparison

Comparison of common governance models for approving smart contract upgrades, detailing key operational and security characteristics.

Governance FeatureMultisigToken Voting (e.g., Compound)Time-Lock Executor (e.g., OZ Governor)

Approval Threshold

M-of-N signers

Quorum (e.g., 4%) + Majority

Quorum + Majority, then Time-Lock

Voting Duration

N/A (Off-chain coordination)

3 days

Voting: 3 days, Time-Lock: 2 days

Upgrade Execution Speed

Immediate after signatures

Immediate after vote

Delayed by Time-Lock period

On-Chain Transparency

Low (private signing)

High (public votes)

High (public votes & queue)

Resistance to Whale Dominance

High (fixed council)

Low

Medium (delayed execution allows reaction)

Typical Use Case

Early-stage protocols, treasuries

Mature DeFi with distributed token

Protocols requiring user safety period

Gas Cost for Proposal

~$50 (create tx)

~$200 (create & vote)

~$250 (create, vote, queue)

Admin Key Risk

High (keys must be secured)

Eliminated

Eliminated after Time-Lock

code-examples-voting
GOVERNANCE

Code Examples: Casting Votes

A practical guide to programmatically interacting with on-chain governance contracts to approve upgrade proposals.

Casting a vote on-chain is a direct transaction to a smart contract. Most governance systems, like OpenZeppelin's Governor or Compound's GovernorBravo, expose a castVote or castVoteWithReason function. The core parameters are the proposalId (a unique hash identifying the proposal) and your support value (typically 1 for for, 0 against, 2 abstain). Before voting, you must ensure your wallet holds the requisite voting tokens and that the proposal is in an active state. You can check this by calling the contract's state(proposalId) function, which should return 1 (Active).

Here is a basic example using ethers.js to cast a vote for a proposal. This snippet assumes you have a connected signer and the contract ABI. The proposalId is often a bytes32 or uint256 value found on a governance forum or block explorer.

javascript
const governorAddress = '0x...';
const proposalId = '123...';
const support = 1; // Vote FOR

const governorContract = new ethers.Contract(governorAddress, governorABI, signer);

const tx = await governorContract.castVote(proposalId, support);
await tx.wait();
console.log(`Vote cast in transaction: ${tx.hash}`);

Always verify the transaction on a block explorer after submission. Failed votes often result from incorrect proposal states, insufficient voting power, or gas estimation errors.

For a more robust implementation, include gas estimation and error handling. Use castVoteWithReason if the contract supports it, as it provides on-chain transparency for your decision. The reason parameter is a string that will be emitted in an event.

javascript
try {
  const gasEstimate = await governorContract.estimateGas.castVoteWithReason(proposalId, support, reason);
  const tx = await governorContract.castVoteWithReason(proposalId, support, reason, {
    gasLimit: gasEstimate.mul(120).div(100) // Add 20% buffer
  });
  const receipt = await tx.wait();
  console.log(`Vote succeeded. Gas used: ${receipt.gasUsed.toString()}`);
} catch (error) {
  console.error('Failed to cast vote:', error);
}

Remember, voting power is typically calculated at the block number when the proposal was created (proposalSnapshot). Tokens acquired after that snapshot do not count, and tokens delegated to you before the snapshot do.

To vote programmatically for a large holder or DAO treasury, you may need to interact with a Voting Vault or Delegation contract first. For example, if using a smart contract wallet like a Gnosis Safe, you must execute the vote via a SafeTransaction. Furthermore, some protocols like Uniswap use a Governor Bravo style with a timelock; after a vote succeeds, the proposal must be queued and then executed in separate transactions. Always review the specific governance contract's documentation, such as the OpenZeppelin Governor or the protocol's own developer guides, to understand the complete lifecycle.

security-considerations
GOVERNANCE SECURITY

How to Approve Upgrade Proposals

A guide to evaluating and voting on smart contract upgrades, focusing on security risks, technical due diligence, and community alignment.

Voting to approve a smart contract upgrade is a critical governance action with significant security implications. Unlike routine parameter changes, upgrades can modify core protocol logic, introduce new attack vectors, or alter fee structures. Before casting a vote, you must understand the upgrade mechanism itself—whether it uses a transparent proxy pattern like OpenZeppelin's, a UUPS (Universal Upgradeable Proxy Standard), or a diamond proxy (EIP-2535). Each has distinct security properties; for instance, UUPS places upgrade logic in the implementation contract, while transparent proxies keep it in the proxy admin. The timelock period is a crucial safety feature, providing a mandatory delay between proposal approval and execution, allowing users to exit or scrutinize the final code.

Technical due diligence is non-negotiable. Start by verifying the proposal's on-chain hash matches the source code published for review. Scrutinize the diff between the old and new implementations, paying special attention to state variable layout, function visibility changes, and any new external calls. Use tools like Slither or Mythril for automated analysis and review audit reports from reputable firms like Trail of Bits or OpenZeppelin. Check if the upgrade affects integrators and dependencies; a change to a core function's signature could break all existing front-ends and bots. For complex upgrades, consider funding a bug bounty program during the timelock window to crowd-source security review.

Beyond code, evaluate the proposal's process and community impact. Was the discussion period sufficient, and were concerns from delegates and developers adequately addressed? Analyze the upgrade's necessity: does it fix a critical bug, add essential functionality, or is it merely cosmetic? Assess the risk/reward trade-off and the team's contingency plan, including a clear rollback procedure. Finally, consider the social consensus. A highly contentious upgrade, even if technically sound, can fracture a community and damage the protocol's credibility. Your vote should balance technical security, operational necessity, and long-term protocol health.

UPGRADE PROPOSALS

Frequently Asked Questions

Common questions and troubleshooting steps for developers working with smart contract upgrade proposals, focusing on the technical approval process.

A proxy upgrade proposal is a governance mechanism to change the logic of a smart contract while preserving its state and address. It uses a proxy pattern where a Proxy Contract delegates all calls to a Logic Contract. An upgrade proposal points the proxy to a new logic contract address.

Key Components:

  • Proxy Contract: Holds the storage and user funds.
  • Logic Contract: Contains the executable code.
  • ProxyAdmin/Governance: Controls the upgrade authorization.

When a user interacts with the proxy, it uses delegatecall to run the code from the current logic contract. An approved upgrade proposal changes the stored logic contract address in the proxy, instantly changing the contract's behavior for all future calls.

conclusion
GOVERNANCE IN ACTION

Conclusion and Next Steps

You've learned the mechanics of voting on upgrade proposals. This section outlines key security practices and how to stay informed for future governance events.

Successfully approving an upgrade is just one part of responsible protocol governance. To ensure the long-term health and security of the network, you must adopt a security-first mindset. Always verify the proposal's source and the integrity of the transaction data before signing. Use a hardware wallet for voting on mainnet proposals to protect your keys. Be wary of phishing sites impersonating governance interfaces; bookmark the official DAO or protocol dashboard. Remember, your vote often involves moving significant value; treat it with the same caution as a large financial transaction.

Staying informed is critical for effective participation. You should monitor the official governance forums for your protocols, such as the Compound Governance Forum or Uniswap's Agora. Set up notifications for new Snapshot spaces or on-chain proposals. For developers, the next step is to understand the technical implementation: review the upgrade's smart contract code, often hosted on GitHub, and analyze the diff between versions. Tools like Tenderly can help simulate the effects of an upgrade before it goes live.

Your journey doesn't end with a single vote. Consider delegating your voting power to a knowledgeable community member if you lack the time for deep research. Explore advanced tools like Tally or Boardroom for aggregated governance dashboards. To deepen your technical knowledge, study the upgrade patterns of major protocols like OpenZeppelin's Transparent Proxy or the EIP-1967 standard. By combining vigilant security practices with continuous learning, you transition from a passive token holder to an active, informed steward of the decentralized networks you help govern.

How to Approve Upgrade Proposals on Ethereum, Solana, and Cosmos | ChainScore Guides