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

Launching a Retroactive Public Goods Funding Round

A technical guide for DAOs and protocols to implement retroactive public goods funding, covering impact metrics, selection processes, and on-chain distribution.
Chainscore © 2026
introduction
A PRACTICAL GUIDE

Launching a Retroactive Public Goods Funding Round

A step-by-step tutorial for project leads and DAOs on structuring and executing a retroactive funding round to reward past contributions.

Retroactive Public Goods Funding (RetroPGF) is a mechanism where contributors are rewarded for work that has already provided value to an ecosystem. Unlike traditional grants, which are speculative, RetroPGF funds are distributed based on proven impact. This model, pioneered by protocols like Optimism, aligns incentives with tangible outcomes. Launching a round involves defining a scope, identifying eligible contributions, designing a voting mechanism, and distributing funds, typically from a treasury or a matching pool.

The first step is scoping the round. Define the specific ecosystem, time period, and types of contributions you intend to reward. For example, a round could focus on "developer tooling for the Ethereum L2 ecosystem in Q1-Q3 2024" or "educational content for a specific DAO." A clear scope ensures contributors understand eligibility and voters can assess impact consistently. This phase also involves setting the total reward pool, which can be sourced from a protocol treasury, a community fund, or through a matching model like Gitcoin Grants.

Next, you must design the evaluation and voting mechanism. Most rounds use a badgeholder or token-weighted voting system where a curated group assesses contributions. Key decisions include: voter selection criteria, voting interface (like Snapshot or a custom dApp), and the evaluation rubric. The rubric should emphasize metrics like usage, originality, and community benefit. For transparency, all eligible projects should be listed in a public registry with links to their work, such as GitHub repositories, articles, or deployed contracts.

Technical implementation requires setting up the voting infrastructure and fund distribution. For on-chain rounds using Optimism's AttestationStation or EAS, you can create schemas to record contribution data. A simple smart contract for distributing funds based on vote results might involve a merkle distributor for gas-efficient claims. Here's a conceptual snippet for a fund distributor:

solidity
contract RetroPGFDistributor {
    function claim(
        address recipient,
        uint256 amount,
        bytes32[] calldata merkleProof
    ) external {
        // Verify proof against merkle root
        // Transfer tokens to recipient
    }
}

Finally, execute the round with clear communication. Announce the round timeline, rules, and submission process through forums and social channels. After the voting period, calculate results, publish them transparently, and initiate the distribution. Post-round, analyze the outcomes: gather feedback from participants and voters to refine future rounds. Successful RetroPGF rounds, like those run by Optimism Collective, demonstrate that rewarding proven value fosters sustainable ecosystem growth and attracts high-quality contributors.

prerequisites
LAUNCHING A RETROACTIVE PUBLIC GOODS FUNDING ROUND

Prerequisites for Implementation

Before deploying a retroactive funding round, you must establish the foundational technical and strategic components. This guide outlines the essential prerequisites.

A retroactive public goods funding (RetroPGF) round requires a clear funding mandate and a defined evaluation framework. The mandate specifies the round's purpose, such as funding open-source software, protocol research, or educational content. The framework details the criteria for evaluating impact, including technical quality, usage, and community benefit. These documents align contributors, voters, and the coordinating entity, ensuring the round rewards genuine, verifiable public goods. Without this clarity, the allocation process becomes subjective and less effective.

You must select and configure the smart contract infrastructure for vote collection and fund distribution. Most rounds use a quadratic funding mechanism via platforms like Gitcoin Grants Stack or custom-built solutions using the Allo Protocol V2. Prerequisites include deploying a round manager contract, setting the matching pool size, defining the voting period, and configuring sybil resistance (e.g., integrating Gitcoin Passport). Ensure the contract is verified on a relevant blockchain like Ethereum Mainnet, Optimism, or Arbitrum.

Establish a voter identification and qualification system. RetroPGF relies on a knowledgeable electorate. You need a method to identify and invite credible voters, often domain experts or active community members. This involves creating a voter registry, which can be an on-chain NFT badge, a signed attestation, or a managed allowlist. The system must prevent sybil attacks while ensuring a diverse, qualified voter base. Tools like EAS (Ethereum Attestation Service) can be used to issue verifiable credentials for voters.

Prepare the data and evidence pipeline for project applications. Contributors must submit proof of their work's impact. Your system should define required evidence, such as GitHub repository links, usage metrics (e.g., download counts, contract interactions), testimonials, or documentation. Consider using standardized schemas like Project Hypercerts for impact claims. You'll need a frontend application portal (like a grants hub) and a backend to aggregate and display this data for voters, making the evaluation process transparent and data-driven.

Secure funding and multisig management for the matching pool. RetroPGF requires capital to distribute. This is typically held in a multi-signature wallet (e.g., Safe) controlled by trusted round operators. You must decide on the token (ETH, OP, ARB, USDC) and fund the contract before the round opens. Establish clear operational procedures for triggering the final distribution from the smart contract after voting concludes, ensuring funds are dispersed securely and according to the final results.

step-1-define-scope-metrics
FOUNDATION

Step 1: Define Funding Scope and Impact Metrics

The first and most critical step in launching a retroactive funding round is to clearly define what you are funding and how you will measure its success. This establishes the program's legitimacy and ensures capital is allocated effectively.

A retroactive public goods funding (RPGF) round rewards projects that have already demonstrated value to an ecosystem. Unlike a grant, which funds future work, RPGF assesses past contributions. Therefore, your funding scope must precisely define the category of work eligible for rewards. Common scopes include: core protocol infrastructure, developer tooling, security audits, educational content, and community growth initiatives. A well-defined scope prevents ambiguity and focuses the evaluation process on comparable projects.

Once the scope is set, you must establish impact metrics. These are the measurable outcomes used to judge a project's contribution. Good metrics are specific, verifiable, and aligned with the scope's goals. For developer tooling, metrics might include GitHub stars, download counts, or integrations with other major protocols. For educational work, metrics could be unique readers, translation efforts, or citations in developer documentation. Avoid vanity metrics; focus on data that proves real adoption and utility.

The chosen metrics directly influence the evaluation methodology. Will you use quantitative data dashboards, qualitative community reviews, or a hybrid model? For example, the Optimism Collective's RPGF rounds often use a badgeholder system, where community-nominated experts assess projects against predefined criteria. Your methodology should be transparent and resistant to gaming. Publishing the scoring rubric in advance allows projects to understand how they will be judged.

Finally, integrate your scope and metrics into the round's on-chain mechanics. This often involves creating a detailed description in the round's smart contract or frontend interface, using frameworks like Ethereum Attestation Service (EAS) to create schemas for project submissions and reviews. Clearly documented parameters ensure all participants—applicants, voters, and funders—operate with the same expectations, which is essential for the fairness and success of the funding round.

step-2-design-selection-process
RETROACTIVE FUNDING

Design the Selection and Evaluation Process

Establish a transparent, objective, and defensible framework for identifying and rewarding past contributions that created public value.

The core of a retroactive funding round is the selection and evaluation process. This framework determines which projects or contributors are eligible and how their impact is measured. A well-designed process must be transparent, objective, and resistant to gaming. Key decisions include defining the eligibility criteria (e.g., projects must be open-source, non-extractive, and deployed on a specific chain), the evaluation metrics (e.g., user count, total value secured, code commits), and the timeline for the contribution period being rewarded.

Common evaluation methodologies include quantitative on-chain metrics, qualitative committee review, or a hybrid model. For example, Optimism's RetroPGF rounds use a badgeholder system where community-nominated individuals vote on project impact. Your design should specify the data sources (like The Graph for querying usage or Dune Analytics for financial metrics) and the weighting of different factors. Will you prioritize technological innovation, user adoption, or financial sustainability? Documenting these weights upfront is critical for legitimacy.

To implement this programmatically, you often need to collect and analyze data. A basic script using the Dune API might fetch transaction volumes for a list of contract addresses submitted by applicants. Here's a conceptual snippet in Python:

python
import requests
# Fetch query results for a Dune Analytics query tracking contract interactions
dune_query_id = '1234567'
response = requests.get(f'https://api.dune.com/api/v1/query/{dune_query_id}/results')
metrics_data = response.json()
# Process data to calculate a score based on unique users and volume

This data can then feed into a scoring algorithm defined in your evaluation criteria.

Finally, establish a clear appeals or dispute resolution process. Even with automated checks, edge cases and disputes will arise. Publish the full evaluation rubric and a method for applicants to contest decisions or provide additional context. This step transforms your round from a simple grant into a robust, community-trusted mechanism for value alignment, setting the stage for the subsequent steps of fund distribution and governance.

PROJECT SELECTION

Comparison of Selection Models

A comparison of common models for selecting projects in a retroactive public goods funding round.

Selection CriterionDirect VotingExpert CommitteeQuadratic Funding

Primary Decision Maker

Token Holders / Community

Appointed Panel

Donor Contributions

Resistance to Sybil Attacks

Partial (via sybil resistance mechanisms)

Voter Incentive Alignment

Low (one-token-one-vote)

High (reputational stake)

High (matching funds)

Typical Funding Cycle

1-3 months

3-6 months

1-2 months

Average Administrative Overhead

Low

High

Medium

Transparency of Process

High

Medium (deliberations may be private)

High

Examples in Practice

Snapshot, Tally

Optimism Citizens' House, Gitcoin Grants Stack

Gitcoin Grants, clr.fund

step-3-build-distribution-mechanism
IMPLEMENTATION

Step 3: Build the Fund Distribution Mechanism

This step covers the core smart contract logic for distributing funds to approved projects based on the results of your voting round.

The fund distribution mechanism is the smart contract that executes the final allocation of funds. It takes the merkle root generated in Step 2 as its primary input. This root cryptographically commits to the final list of recipient addresses and their awarded amounts. By using a Merkle tree, the contract can verify individual claims without storing the entire list on-chain, saving significant gas costs. The standard pattern is a MerkleDistributor contract, where approved projects (or their delegates) submit a claim transaction with their proof.

Here is a simplified core function from a distributor contract, based on the Uniswap Merkle Distributor:

solidity
function claim(uint256 index, address account, uint256 amount, bytes32[] calldata merkleProof) external {
    require(!isClaimed(index), "Drop already claimed.");
    // Verify the Merkle proof.
    bytes32 node = keccak256(abi.encodePacked(index, account, amount));
    require(MerkleProof.verify(merkleProof, merkleRoot, node), "Invalid proof.");
    // Mark it claimed and send the token.
    _setClaimed(index);
    require(IERC20(token).transfer(account, amount), "Transfer failed.");
    emit Claimed(index, account, amount);
}

The function checks that the claim hasn't been processed, validates the provided merkleProof against the stored merkleRoot, and then transfers the amount of tokens to the account.

You must decide on key distribution parameters: the token used for payment (e.g., USDC, ETH, a project's governance token), the total funding pool amount, and the claim deadline. The contract should hold the total pool of funds and allow only successful Merkle proof submissions to withdraw. It's critical to include a withdrawal function for the round operator to recover unclaimed funds after the deadline passes, ensuring capital isn't permanently locked. This function should be timelocked or governed by a multisig for security.

For retroactive funding rounds like those inspired by Optimism's RetroPGF, the distribution is often multi-step. A first distribution might occur immediately post-voting, with provisions for future rounds or streaming payments via protocols like Sablier or Superfluid. Your contract could be designed to work with a Vesting contract that drips funds to recipients over time, aligning incentives for long-term contribution. Consider whether you need a dispute period where claims can be challenged before funds are released, adding a layer of fraud protection.

Before deployment, thoroughly test the distribution mechanism. Use a testnet to simulate the full flow: seeding the contract with test tokens, generating a Merkle tree from dummy data, and having multiple addresses successfully claim. Key tests should verify: proof verification fails with incorrect data, double claims are prevented, and the admin can recover unclaimed funds. Audit the contract, especially the Merkle proof verification and token transfer logic, as these hold the actual value. A well-built distributor is a trust-minimized, efficient engine that turns voting results into executed funding.

code-example-distributor
RETROACTIVE FUNDING

Code Example: Merkle Distributor Contract

A technical walkthrough of a Merkle distributor smart contract for efficiently distributing retroactive rewards to a large, predefined set of recipients.

A Merkle distributor is a smart contract pattern for efficiently distributing tokens or ETH to a large list of recipients. Instead of storing all addresses and amounts on-chain—which is prohibitively expensive—the contract stores only a single cryptographic hash: the Merkle root. This root is computed from a Merkle tree where each leaf is a hash of a recipient's address and their allocated amount. To claim, a user submits a Merkle proof, a small set of hashes that proves their leaf's inclusion in the tree. This design minimizes gas costs for deployment and shifts the proof generation and submission cost to the individual claimants.

The core logic resides in a claim function. It verifies the submitted proof against the stored Merkle root and marks the leaf as claimed to prevent double-spending. A typical implementation includes:

  • merkleRoot: The public root hash set at deployment.
  • token: The address of the ERC-20 token to distribute.
  • isClaimed: A mapping to track claimed leaves.
  • function claim(address account, uint256 amount, bytes32[] calldata merkleProof). The function hashes account and amount to recreate the leaf, then uses the merkleProof to verify it matches the merkleRoot. If valid, it transfers the amount to the account.

For a retroactive public goods funding round, an off-chain process is required first. The funding entity creates a list of recipient addresses and corresponding award amounts. This list is used to generate the Merkle tree and its root. The root is then committed to the contract upon deployment. The complete list and the Merkle proofs for each recipient are published, often via a cryptographically signed attestation or on IPFS, allowing users to independently verify their inclusion. This pattern has been used by major airdrops like Uniswap's UNI distribution and the Optimism Retroactive Public Goods Funding rounds.

Key security considerations include ensuring the Merkle root is correct and immutable, protecting against front-running, and using a robust proof generation library. The contract should use SafeERC20 for token transfers and implement a onlyOwner function to recover unclaimed funds after a deadline. Developers must also be cautious of the ERC-20 transfer gas cost variability; for large distributions, it may be preferable to use a pull-based pattern where users withdraw rather than receive a direct transfer.

step-4-execute-communicate-round
LAUNCHING A RETROACTIVE PUBLIC GOODS FUNDING ROUND

Step 4: Execute the Round and Communicate Results

This step covers the operational execution of your funding round, from deploying the contract and distributing funds to transparently communicating outcomes to your community and stakeholders.

With your round parameters finalized and the smart contract deployed, the execution phase begins. The core action is to trigger the contract's distribution function, which allocates funds to the approved recipient addresses based on the finalized results. For a round using the Allo Protocol v2, this involves calling the distribute function on your DonationVotingMerkleDistributionStrategy contract. This function requires the Merkle root of your results and the distribution metadata, which you can generate using the Allo SDK. Ensure you have sufficient native gas tokens (like ETH, MATIC, or OP) to cover the transaction fees for the distribution, which can be significant if sending to hundreds of recipients.

Immediately after the distribution transaction is confirmed, you must publish the results. Transparency is non-negotiable for trust in retroactive funding. This involves publishing the full dataset used for the Merkle tree: the list of recipient addresses, their allocated amounts, and the proof of inclusion. Host this data in a permanent, verifiable location such as IPFS (using a service like Pinata or web3.storage) or GitHub. Include a clear README explaining the round's scope, evaluation criteria, and the final decision-making process. This allows any community member to independently verify that their allocation (or any other) is correct by reconstructing the Merkle proof.

Communication is the final, critical component. Craft a public announcement that covers: the round's total capital distributed, the number of projects funded, a link to the published results data, and the on-chain transaction hash for the distribution. Use your project's primary channels—Discord, Twitter, governance forums, and a blog post**. For each funded project, consider sending a direct notification. This not only ensures they claim their funds but also fosters a positive relationship. Effective communication closes the feedback loop, demonstrates accountability, and sets a precedent of transparency for future rounds, encouraging greater participation and trust in the ecosystem.

RETROACTIVE FUNDING

Frequently Asked Questions

Common questions and solutions for developers launching a retroactive public goods funding round on EVM chains.

Retroactive public goods funding (RetroPGF) is a mechanism that rewards past contributions to open-source software, infrastructure, or research after their value has been proven. On-chain implementations, like those using the Allo Protocol or custom smart contracts, automate the distribution of funds based on community voting or a predefined meritocratic formula.

Key on-chain components:

  • Registry Contract: A smart contract that lists eligible projects and contributors.
  • Funding Pool: A vault (often managed by a Safe multisig) holding the round's capital, typically in ERC-20 tokens like USDC.
  • Voting/Vetting Mechanism: A system (e.g., token-weighted voting, quadratic funding, or a panel) that determines allocation amounts on-chain.
  • Distribution Module: A contract that executes the payout transactions to recipient addresses after the round concludes.

This creates a transparent, programmable, and trust-minimized way to fund public goods, moving beyond traditional grant committees.

common-pitfalls
RETROACTIVE FUNDING

Common Implementation Pitfalls

Avoiding these critical mistakes can mean the difference between a successful funding round and a failed initiative that wastes resources and community goodwill.

06

Centralized Arbiters in a Decentralized Process

Over-reliance on a core team or foundation to make final funding decisions contradicts the decentralized ethos and creates a single point of failure/bias.

Anti-pattern: A "decentralized" committee that can unilaterally veto or alter results.

Best Practice: Design the round so the outcome is determined algorithmically based on transparent, on-chain inputs. The organizing entity should only handle edge-case appeals or clear fraud, with rules for these exceptions defined in advance.

>30 rounds
Run via clr.fund
conclusion-next-steps
IMPLEMENTATION SUMMARY

Conclusion and Next Steps

You have now completed the core steps to launch a retroactive public goods funding round using smart contracts and on-chain data.

Launching a retroactive funding round is a powerful mechanism to reward past contributions without upfront capital. The process involves defining clear evaluation criteria, sourcing verifiable on-chain data for proof-of-work, and deploying a secure distribution contract like a Merkle distributor. Key technical decisions include selecting a data source (e.g., The Graph for querying historical interactions, Dune Analytics for complex metrics), designing a fair reward formula, and ensuring the final Merkle root is correctly committed on-chain for claim verification.

For next steps, consider enhancing your round's design and execution. Implement a frontend claim portal using libraries like @uniswap/merkle-distributor to allow users to easily verify and claim their allocations. Plan for round sustainability by establishing a multisig treasury for the funds and documenting the round's rules and outcomes transparently on platforms like GitHub or Mirror. For subsequent rounds, you can iterate by incorporating community feedback, adjusting metrics, or using more sophisticated data analysis to capture different types of contributions.

To deepen your understanding, explore related concepts and tools. Study other funding models like continuous or proactive funding rounds to understand the full spectrum of options. Review successful case studies from protocols like Optimism, which has run multiple retroactive funding rounds (RetroPGF) to reward ecosystem development. For technical depth, examine the source code for popular distribution contracts and consider security audits for production deployments. The goal is to create a repeatable, transparent, and community-trusted process for valuing and rewarding public goods.