> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chainstack.com/llms.txt
> Use this file to discover all available pages before exploring further.

# eth_uninstallFilter | Tempo

> Tempo API method that uninstalls a filter created by eth_newFilter, eth_newBlockFilter, or eth_newPendingTransactionFilter. On Tempo.

Tempo API method that uninstalls a filter created by `eth_newFilter`, `eth_newBlockFilter`, or `eth_newPendingTransactionFilter`. Filters should be uninstalled when no longer needed to free server resources.

## Parameters

* `filterId` — the filter ID to uninstall

## Response

* `result` — `true` if the filter was successfully uninstalled, `false` otherwise

## `eth_uninstallFilter` code examples

<CodeGroup>
  ```javascript ethers.js theme={"system"}
  const ethers = require('ethers');
  const NODE_URL = "CHAINSTACK_NODE_URL";
  const provider = new ethers.JsonRpcProvider(NODE_URL);

  const filterLifecycle = async () => {
      // Create a block filter
      const filterId = await provider.send("eth_newBlockFilter", []);
      console.log(`Created block filter: ${filterId}`);

      // Use the filter
      const blocks = await provider.send("eth_getFilterChanges", [filterId]);
      console.log(`Got ${blocks.length} new blocks`);

      // Uninstall when done
      const uninstalled = await provider.send("eth_uninstallFilter", [filterId]);
      console.log(`Filter uninstalled: ${uninstalled}`);

      // Trying to use it again will fail
      try {
        await provider.send("eth_getFilterChanges", [filterId]);
      } catch (e) {
        console.log("Filter no longer exists (expected)");
      }
    };

  filterLifecycle();
  ```

  ```python web3.py theme={"system"}
  from web3 import Web3

  node_url = "CHAINSTACK_NODE_URL"
  web3 = Web3(Web3.HTTPProvider(node_url))

  # Create a block filter
  filter_result = web3.provider.make_request("eth_newBlockFilter", [])
  filter_id = filter_result['result']
  print(f"Created block filter: {filter_id}")

  # Use the filter
  changes_result = web3.provider.make_request("eth_getFilterChanges", [filter_id])
  print(f"Got {len(changes_result['result'])} new blocks")

  # Uninstall when done
  uninstall_result = web3.provider.make_request("eth_uninstallFilter", [filter_id])
  print(f"Filter uninstalled: {uninstall_result['result']}")
  ```

  ```bash cURL theme={"system"}
  # First create a filter
  curl -X POST "CHAINSTACK_NODE_URL" \
    -H "Content-Type: application/json" \
    -d '{"jsonrpc": "2.0", "method": "eth_newBlockFilter", "params": [], "id": 1}'

  # Then uninstall it using the returned filter ID
  curl -X POST "CHAINSTACK_NODE_URL" \
    -H "Content-Type: application/json" \
    -d '{"jsonrpc": "2.0", "method": "eth_uninstallFilter", "params": ["0x1"], "id": 1}'
  ```
</CodeGroup>


## OpenAPI

````yaml openapi/tempo_node_api/filter_handling/eth_uninstallFilter.json POST /
openapi: 3.0.0
info:
  title: eth_uninstallFilter Tempo example
  version: 1.0.0
  description: This is an API example for eth_uninstallFilter for Tempo.
servers:
  - url: https://tempo-mainnet.core.chainstack.com/c3ce2925b51f1ed18719fe8a23bbdccf
security: []
paths:
  /:
    post:
      tags:
        - Filter handling
      summary: eth_uninstallFilter
      operationId: tempo-eth-uninstallFilter
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                jsonrpc:
                  type: string
                  default: '2.0'
                method:
                  type: string
                  default: eth_uninstallFilter
                params:
                  type: array
                  items: {}
                  default:
                    - 0x...
                  description: Filter ID to uninstall
                id:
                  type: integer
                  default: 1
      responses:
        '200':
          description: Uninstall status
          content:
            application/json:
              schema:
                type: object
                properties:
                  jsonrpc:
                    type: string
                  id:
                    type: integer
                  result:
                    type: boolean
                    description: true if the filter was successfully uninstalled

````