Skip to main content
Make sure your ComfyUI is updated.Workflows in this guide can be found in the Workflow Templates. If you can’t find them in the template, your ComfyUI may be outdated. (Desktop version’s update will delay sometime)If nodes are missing when loading a workflow, possible reasons:
  1. You are not using the latest ComfyUI version (Nightly version)
  2. Some nodes failed to import at startup
MediaPipe is Google’s open-source machine learning solution for real-time perception. In ComfyUI, MediaPipe Face Detection provides BlazeFace detection, FaceMesh v2 landmark estimation, and ARKit-52 blendshapes — all in a single unified workflow. MediaPipe Face Detection is natively supported in ComfyUI (PR #14009), and the model weights are available under the Apache 2.0 License. MediaPipe GitHub | Comfy-Org Model Repository

Key capabilities

  • Fast face detection — BlazeFace-based detector with short (~2 m) and full (~5 m) range variants
  • 478 facial landmarks — dense FaceMesh v2 keypoints per detected face
  • ARKit-52 blendshapes — real-time facial expression coefficients
  • Face region masks — per-region masks for face oval, lips, eyes, and irises
  • Face bounding boxes — outputs compatible with DrawBBoxes for bounding box visualization
Scope: Face detection only — BlazeFace + FaceMesh v2 + ARKit blendshapes. This does not cover hand, pose, or holistic detection.

MediaPipe Face Detection Workflow

1. Download the Workflow

Update your ComfyUI to the latest version, then go to WorkflowBrowse Templates and find “Mediapipe: Image Face Detection” under the Utility category.

Download JSON Workflow File

Download workflow

Run on Comfy Cloud

Open in cloud

Download Sample Image

Get the example input image for this workflow
MediaPipe Face Detection preview

2. Download the Model

The MediaPipe Face Detection model is hosted on the Comfy-Org MediaPipe model repository. Place it in the following directory structure:

3. Using the Workflow

This workflow uses a subgraph node that orchestrates face detection, visualization, and mask generation. The subgraph exposes the following controls:

Learn about Subgraph

This workflow uses Subgraph nodes for modular processing. Check out the Subgraph documentation to learn how to customize and extend the workflow.
Subgraph inputs: Subgraph parameters: Mask toggles use custom mode internally: only checked regions are filled; multiple ON regions are unioned into one mask per frame. Subgraph outputs:

4. Run the Workflow

  1. Ensure the model file is placed in ComfyUI/models/detection/
  2. Load an image in the Load Image node
  3. Adjust detection parameters as needed
  4. Click Queue or use Ctrl(Cmd) + Enter to run
  5. The workflow outputs the mesh overlay, bounding boxes, and mask preview

Community Resources