Nodes/ComfyUI-EZ-AF-Nodes/EZ Find & Replace
ComfyUI Node

EZ Find & Replace

A bare-bones find/replace that does what it says

By ez-af·Created 2 years ago·Updated 3 months ago· 28
EZ Find & Replace
    • STRING
    string
    find
    replace

    EZ Find & Replace is exactly as exciting as it sounds: it takes a string, finds every instance of one substring, and replaces it with another. It's the kind of node you don't think about until you need it - swapping a model-specific quality tag across a long prompt, cleaning , , artifacts out of a concatenated text, or scrubbing a character name out of a shared preset. There's no cleverness here, and that's the point: it's the utility the pack author wanted for his own workflows and just shipped with the pack.

    How it works

    Three inputs, one output, no modes to misconfigure:

    • string - the text to process (multiline).
    • find - the substring to look for.
    • replace - what to swap it in with.

    It's a plain Python replace, meaning it replaces every occurrence - find of red will also hit the red inside bored - and an empty find leaves the string untouched rather than doing anything weird. The replace field defaults to empty, which makes it a quick way to delete a token too: find , with a blank replace and you've stripped your commas.

    The honest take

    The author's README says it straight: nodes like this one are "for testing purposes" and he recommends ComfyUI core nodes for basic text work. That's fair - ComfyUI has a built-in Find and Replace node (Text Find and Replace in core) that does the same job with zero extra install. So why would you reach for this one? Mainly if you're already running the EZ-AF pack and you want the same node in a single workflow that also uses EZ Text Concatenate and the loaders, or if the core node's exact behavior has annoyed you enough to try the alternative. Both do substring replacement; there's no feature gap either way.

    The one thing this node does that the README undersells: because the input is forceInput-style STRING, it slots cleanly into a text-pipeline chain - loader output in, cleaned text out, straight into the next concat stage.

    Install

    Part of EZ-AF Nodes:

    cd ComfyUI/custom_nodes
    git clone https://github.com/ez-af/ComfyUI-EZ-AF-Nodes.git
    

    restart (or ComfyUI Manager → search ez-af). No models, no extra deps beyond the pack's aiohttp/Pillow.

    Where it can trip you up

    The all-occurrences behavior is the main surprise - if you only wanted the first match you'd need a different tool (or to craft your find string to be unique enough). And there's no regex support, so a pattern like \d+ will just be treated as literal characters. For a beginner the honest guidance is: if you need this and don't have the pack installed yet, the core node is the less-dependency path. If you've got the pack, this one's perfectly serviceable and you don't need to double-install.

    CategoryEZ NODES

    Inputs (3)

    NameTypeDefaultDescription
    stringSTRING
    findoptSTRING
    replaceoptSTRING

    Outputs (1)

    NameTypeDescription
    STRINGSTRING