ComfyUI Node: keys

Class Name

Basic data handling: DictKeys

Category
Basic/DICT
Author
StableLlama (Account age: 861days)
Extension
Basic data handling
Latest Updated
2026-05-07
Github Stars
0.04K

How to Install Basic data handling

Install this extension via the ComfyUI Manager by searching for Basic data handling
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter Basic data handling in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

keys Description

The `DictKeys` node extracts all keys from a dictionary for efficient key-based operations.

keys:

The DictKeys node is designed to extract all the keys from a given dictionary, providing a straightforward way to access and utilize the keys within your data structures. This node is particularly useful when you need to iterate over keys, perform operations based on key names, or simply need a list of all keys for further processing. By focusing solely on the keys, this node helps streamline workflows that require key-based operations, making it an essential tool for managing and manipulating dictionary data efficiently.

keys Input Parameters:

input_dict

The input_dict parameter is the dictionary from which you want to extract the keys. This parameter is crucial as it serves as the source of data for the node's operation. The dictionary should be structured with key-value pairs, where the keys are the elements you wish to retrieve. There are no specific minimum or maximum values for this parameter, but it must be a valid dictionary. The default value is an empty dictionary, which would result in an empty list of keys.

keys Output Parameters:

keys

The keys output parameter provides a list of all the keys extracted from the input dictionary. This list is essential for any operations that require knowledge of the dictionary's structure, such as iterating over keys or checking for the presence of specific keys. The output is a straightforward list, making it easy to integrate into other processes or nodes that require key information.

keys Usage Tips:

  • Use the DictKeys node when you need to perform operations that are dependent on the keys of a dictionary, such as filtering or mapping tasks.
  • Combine this node with other nodes that require a list of keys to enhance your data processing workflows, ensuring that you have a clear understanding of the dictionary's structure.

keys Common Errors and Solutions:

Invalid dictionary input

  • Explanation: This error occurs when the input provided is not a valid dictionary.
  • Solution: Ensure that the input to the input_dict parameter is a properly formatted dictionary with key-value pairs.

Empty dictionary input

  • Explanation: If the input dictionary is empty, the output will be an empty list of keys.
  • Solution: Verify that the dictionary contains the expected data before passing it to the node to ensure meaningful output.

keys Related Nodes

Go back to the extension to check out more related nodes.
Basic data handling
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Models, enabling artists to harness the latest AI tools to create incredible art.

keys