ComfyUI > Nodes > Basic data handling > rsplit (from data list)

ComfyUI Node: rsplit (from data list)

Class Name

Basic data handling: StringRsplitDataList

Category
Basic/STRING
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

rsplit (from data list) Description

Splits a string into substrings from the right using a specified separator, with optional max splits.

rsplit (from data list):

The StringRsplitDataList node is designed to split a given string into a list of substrings, starting from the rightmost part of the string. This node is particularly useful when you need to break down a string into its components based on a specified separator, but you want to control the splitting process from the end of the string rather than the beginning. This can be beneficial in scenarios where the structure of the string is such that the most relevant information is located towards the end. The node allows for an optional maximum number of splits, providing flexibility in how the string is divided. If no separator is specified, the node defaults to using whitespace as the separator, making it versatile for various text processing tasks.

rsplit (from data list) Input Parameters:

string

The string parameter is the main input for the node, representing the text that you want to split. It is a required parameter and should be provided as a string. The default value is an empty string, which means if no input is given, the node will not perform any operation. This parameter is crucial as it determines the content that will be processed and split into a list of substrings.

sep

The sep parameter specifies the separator at which the string will be split. It is an optional parameter and can be provided as a string. If the separator is not specified or is set to an empty string, the node defaults to using any whitespace as the separator. This parameter allows you to define the specific character or sequence of characters that will be used to divide the string, providing control over how the string is segmented.

maxsplit

The maxsplit parameter determines the maximum number of splits that will be performed on the string. It is an optional integer parameter with a default value of -1, which indicates that there is no limit on the number of splits. The minimum value is -1, allowing for unlimited splits, while setting a positive integer will limit the number of splits to that value. This parameter is useful for controlling the extent of the splitting process, especially when you only need a certain number of components from the end of the string.

rsplit (from data list) Output Parameters:

STRING

The output of the StringRsplitDataList node is a data list of strings, represented by the STRING parameter. This output contains the substrings resulting from the split operation, organized in a list format. Each element in the list corresponds to a segment of the original string, split according to the specified separator and maximum number of splits. This output is essential for further processing or analysis, as it provides a structured way to access the individual components of the original string.

rsplit (from data list) Usage Tips:

  • Use the sep parameter to specify a custom separator if your string contains specific delimiters, such as commas or semicolons, to ensure accurate splitting.
  • Adjust the maxsplit parameter to limit the number of splits if you only need a certain number of components from the end of the string, which can be useful for extracting specific information.
  • If your string contains multiple spaces or tabs, leaving the sep parameter empty will automatically split the string based on any whitespace, simplifying the process for text with inconsistent spacing.

rsplit (from data list) Common Errors and Solutions:

Empty string input

  • Explanation: If the string parameter is left empty, the node will not perform any operation, resulting in an empty output.
  • Solution: Ensure that the string parameter is populated with the text you wish to split before executing the node.

Invalid separator

  • Explanation: Providing a separator that does not exist in the string will result in the entire string being returned as a single element in the list.
  • Solution: Verify that the sep parameter matches the actual delimiters present in the string to achieve the desired splitting.

Negative maxsplit value

  • Explanation: A negative value for maxsplit is interpreted as no limit, which might not be the intended behavior if a specific number of splits is desired.
  • Solution: Set the maxsplit parameter to a positive integer to limit the number of splits if needed.

rsplit (from data list) 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.

rsplit (from data list)