Categories

AI Face Compare (1:1)

Compare two images, output embedding distance and match boolean by threshold, only compare the first face in each image

Click to upload file or drag and drop file here

Maximum file size: 30MB Supported formats: image/*

Click to upload file or drag and drop file here

Maximum file size: 30MB Supported formats: image/*

Key Facts

Category
AI Tools
Input Types
file, number
Output Type
json
Sample Coverage
4
API Ready
Yes

Overview

The AI Face Compare tool performs a 1:1 facial similarity check between two images. It calculates an embedding distance and returns a match boolean based on a configurable threshold, analyzing only the first detected face in each image.

When to Use

  • When you need to verify if two photos depict the same person for identity confirmation.
  • For detecting duplicate or similar faces in image databases or collections.
  • In automated systems requiring face matching for access control or authentication workflows.

How It Works

  • Upload the first image (Image A) containing a face.
  • Upload the second image (Image B) for comparison.
  • Optionally adjust the match threshold and minimum confidence settings to tune sensitivity.
  • The tool extracts the first face from each image, computes the embedding distance, and outputs a JSON with distance and match result.

Use Cases

Identity verification in online services or KYC (Know Your Customer) processes.
Organizing photo libraries by identifying and grouping similar faces.
Enhancing security systems by matching faces for access control or surveillance.

Examples

1. Employee ID Photo Verification

Background
An HR department needs to confirm that a new employee's submitted photo matches their official ID photo.
Problem
Manual comparison is time-consuming and can lead to errors in identity verification.
How to Use
Upload the ID photo as Image A and the new photo as Image B, then set the threshold to 0.6 for reliable matching.
Outcome
The tool outputs a match result, enabling automated and accurate identity confirmation.

2. Detect Duplicate Profile Pictures

Background
A social media platform wants to identify duplicate accounts by comparing profile images.
Problem
Users may create multiple accounts using the same or similar photos, violating platform policies.
How to Use
Compare suspected duplicate images using the tool with a threshold of 0.5 to flag potential matches.
Outcome
A low embedding distance indicates similar faces, helping to detect and review duplicate accounts.

Try with Samples

image, barcode, file

Related Hubs

FAQ

What does the tool output?

It returns a JSON object with the embedding distance and a boolean indicating if the faces match based on the threshold.

What if no face is detected in an image?

The tool may fail or return an error if a face is not found in one or both images.

How is the threshold used?

Faces are considered a match if the embedding distance is below the threshold; a lower value makes matching stricter.

Can it compare multiple faces in one image?

No, it only compares the first detected face in each image.

What image formats are supported?

Common formats like JPEG and PNG are supported, as specified by the file input options.

API Documentation

Request Endpoint

POST /en/api/tools/ai-face-compare

Request Parameters

Parameter Name Type Required Description
imageA file (Upload required) Yes -
imageB file (Upload required) Yes -
threshold number No -
minConfidence number No -

File type parameters need to be uploaded first via POST /upload/ai-face-compare to get filePath, then pass filePath to the corresponding file field.

Response Format

{
  "key": {...},
  "metadata": {
    "key": "value"
  },
  "error": "Error message (optional)",
  "message": "Notification message (optional)"
}
JSON Data: JSON Data

AI MCP Documentation

Add this tool to your MCP server configuration:

{
  "mcpServers": {
    "elysiatools-ai-face-compare": {
      "name": "ai-face-compare",
      "description": "Compare two images, output embedding distance and match boolean by threshold, only compare the first face in each image",
      "baseUrl": "https://elysiatools.com/mcp/sse?toolId=ai-face-compare",
      "command": "",
      "args": [],
      "env": {},
      "isActive": true,
      "type": "sse"
    }
  }
}

You can chain multiple tools, e.g.: `https://elysiatools.com/mcp/sse?toolId=png-to-webp,jpg-to-webp,gif-to-webp`, max 20 tools.

Supports URL file links or Base64 encoding for file parameters.

If you encounter any issues, please contact us at [email protected]