---
title: "Split with Regex"
description: "Local-first visual environment for building and running AI workflows. Build agents visually, deploy anywhere, privacy by design."
canonical: https://docs.nodetool.ai/nodes/nodetool/text/splitwithregex
markdown: https://docs.nodetool.ai/nodes/nodetool/text/splitwithregex.md
product: NodeTool
source: https://github.com/nodetool-ai/nodetool/blob/main/docs/nodes/nodetool/text/splitwithregex.md
---

# Split with Regex

**Type:** `nodetool.text.RegexSplit`

**Namespace:** `nodetool.text`

## Description

Split text using a regex pattern as delimiter.
    regex, split, tokenize

    Use cases:
    - Parse structured text
    - Extract fields from formatted strings
    - Tokenize text

## Properties

| Property | Type | Description | Default |
|----------|------|-------------|---------|
| text | `str` | Text to split | `` |
| pattern | `str` | Regular expression pattern to split on | `` |
| maxsplit | `int` | Maximum number of splits (0 for unlimited) | `0` |

## Outputs

| Output | Type | Description |
|--------|------|-------------|
| output | `list[str]` |  |

## Related Nodes

Browse other nodes in the [nodetool.text](./) namespace.
