Skip to main content

Try it Live

Run EventLog examples in the interactive playground

    Filter Semantics

    Null Wildcard

    null at any position matches any topic value:

    Single Hash Match

    Specific hash must match exactly at that position:

    Array of Hashes (OR Logic)

    Matches if log topic equals ANY hash in the array:

    Empty Filter Array

    Empty filter matches all logs:

    Usage Patterns

    ERC-20 Transfer Filtering

    Multiple Event Types

    Intra-Group Transfers

    DEX Swap Monitoring

    NFT Transfer Tracking

    Anonymous Event Handling

    Advanced Patterns

    Complex Boolean Logic

    Partial Filter (Fewer Topics)

    Filter can have fewer topics than log:

    Empty Topics Check

    Performance

    Uses constant-time hash comparison for security:
    For large datasets, use filterLogs for optimized batch filtering:

    See Also