CLIP Set Last Layer node in ComfyUI
CLIP Set Last Layer is the ComfyUI equivalent of "clip skip": it stops the text encoder a few layers early (-2 is the common setting for anime and Pony models).
Node pack: ComfyUI core
Category: Conditioning and prompts
What CLIP Set Last Layer does
CLIP has 12 (SD 1.5) or 24 (SDXL) transformer layers. Some models were trained with the output of the second-to-last layer rather than the last one, which is called clip skip 2 in other interfaces. CLIP Set Last Layer takes a CLIP, truncates it at the chosen layer and returns the modified CLIP for the prompt nodes.
The value is negative: -1 is the normal full encoder, -2 skips one layer, and so on. Most anime checkpoints, NovelAI descendants, Pony and many Illustrious merges recommend -2. Realistic SD 1.5 and SDXL base models usually expect -1.
Inputs
Name | Type | What it is |
|---|---|---|
clip | CLIP | The text encoder from the checkpoint or LoRA loader. |
stop_at_clip_layer | INT | -1 (no skip) down to -24. -2 equals clip skip 2. |
Outputs
Name | Type | What it is |
|---|---|---|
CLIP | CLIP | The truncated encoder for CLIP Text Encode. |
AD

Skip the setup: ComfyUI workflows preinstalled on the cloud
BitVector runs ready-made ComfyUI workflows on its own GPUs. No install, no missing nodes, no red boxes. Open it on your phone or laptop and generate in a minute.
How to use CLIP Set Last Layer
- Insert the node between the loader CLIP output and the CLIP Text Encode nodes.
- Set stop_at_clip_layer to the value from the model page (-2 for most anime models).
- Wire both prompt nodes to this node output.
Settings and tips
- Put it after Load LoRA so the LoRA patches the full encoder first.
- If a model page says "clip skip 1", leave the node out; it equals -1.
- Changing the value changes the look of the same prompt noticeably; compare -1 and -2 before settling.
Troubleshooting CLIP Set Last Layer
Anime model looks muddy, generic or off-style
Why it happens
The model expects clip skip 2 and the graph encodes with the full CLIP.
How to fix it
Add CLIP Set Last Layer at -2 before the prompt nodes.
The setting has no effect
Why it happens
The prompt nodes are still connected to the original CLIP, bypassing this node.
How to fix it
Rewire both CLIP Text Encode nodes to the output of CLIP Set Last Layer.
Error on Flux or SD3 workflows
Why it happens
T5-based encoders do not support layer truncation the same way; the node is meant for CLIP-L/G.
How to fix it
Remove the node from Flux and SD3 graphs; those models do not use clip skip.
AD

Run this workflow from your phone
Every workflow on this page is preinstalled on BitVector with the models and custom nodes already in place. Pick one, type a prompt, done. Zero setup, nothing to download.
Questions about CLIP Set Last Layer
Is -2 the same as clip skip 2 in AUTOMATIC1111?
Yes, exactly.
Does it affect LoRAs?
Only the text encoder part; place the node after Load LoRA.
Related nodes
CLIP Text Encode (Prompt)
ComfyUI core
CLIP Text Encode turns a text prompt into CONDITIONING using the model text encoder. One node holds the positive prompt, a second one the negative prompt.
Load Checkpoint
ComfyUI core
Load Checkpoint (CheckpointLoaderSimple) opens a .safetensors or .ckpt model file and hands out the three parts every workflow needs: the diffusion MODEL, the CLIP text encoder and the VAE.
Load LoRA
ComfyUI core
Load LoRA (LoraLoader) applies a LoRA file to the MODEL and CLIP with separate strengths, so a style, character or concept can be added to any checkpoint without merging.
AD

Tired of fixing nodes? Let the cloud do it
BitVector keeps hundreds of ComfyUI workflows installed, updated and tested on fast cloud GPUs. No Python, no CUDA errors, no VRAM limits. Works from any browser.
More ComfyUI nodes
ComfyUI Manager
ComfyUI-Manager
ComfyUI Manager is the extension that installs, updates and fixes custom node packs and models from inside the interface, resolves missing nodes in imported workflows and snapshots your setup.
KSampler
ComfyUI core
KSampler runs the denoising loop: it takes the model, prompts and a latent and produces the finished latent image, controlled by seed, steps, cfg, sampler, scheduler and denoise.
Save Image
ComfyUI core
Save Image writes the IMAGE tensor to ComfyUI/output as a PNG, with the whole workflow embedded in the file metadata so the picture can be dragged back into ComfyUI to restore the graph.
VAE Decode
ComfyUI core
VAE Decode converts the sampled LATENT into a pixel IMAGE with the VAE; VAE Decode (Tiled) does the same in tiles for very large images.
Empty Latent Image
ComfyUI core
Empty Latent Image creates the blank latent canvas (width, height, batch_size) that text-to-image sampling starts from; dimensions must be multiples of 8 and match the model family.
Load Image
ComfyUI core
Load Image reads a picture from the ComfyUI input folder (or an upload) and outputs an IMAGE tensor plus a MASK taken from the alpha channel, the starting point for img2img, inpainting, ControlNet and IP-Adapter graphs.

Model
Trends
.ai
© ModelTrends.ai
|
Made in Japan
|
© 2026