Skip to content
masterclass Buddy

LangChain · Class

RecursiveCharacterTextSplitter

RecursiveCharacterTextSplitter breaks text into size-limited chunks while trying to keep paragraphs, sentences, and words together. It checks separators in order and falls back to smaller units when needed.

Last updated

Since
v0.0

Syntax

RecursiveCharacterTextSplitter(separators: list[str] | None = None, keep_separator: bool | Literal['start', 'end'] = True, is_separator_regex: bool = False, **kwargs: Any)

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • TextSplitter
  • create_documents
  • split_documents
  • from_huggingface_tokenizer
  • from_tiktoken_encoder
  • transform_documents
  • get_separators_for_language

Source: Splitting recursively - Text splitter integration guide - Docs by LangChain. Checked 2026-11-03.