Skip to main content

Seamless Face Matching in React Native with Didit's SDK

Implement robust 1:1 face matching in your React Native applications using Didit's powerful SDK. This guide covers installation, integration, and handling verification results, ensuring a secure and user-friendly identity.

Seamless Face Matching in React Native with Didit's SDK

Contents

In this guide

Jump to the part you need.

Effortless IntegrationDidit's React Native SDK simplifies the integration of advanced face matching, liveness detection, and NFC verification into your mobile applications with minimal code.

Robust Security FeaturesBenefit from 1:1 Face Match, Passive & Active Liveness, and ID Verification to ensure the person presenting the document is its legitimate owner, preventing fraud and spoofing attempts.

Configurable Verification WorkflowsCustomize face match thresholds to automatically approve, review, or decline sessions based on similarity scores and risk factors, aligning with your specific business needs and compliance requirements.

Didit's AdvantageDidit provides an AI-native, modular identity platform with a Core KYC tier, making enterprise-grade identity verification accessible and scalable for all developers.

In today's digital-first world, secure and seamless identity verification is paramount for mobile applications. Whether you're onboarding new users, securing transactions, or complying with regulatory requirements, ensuring that a user is who they claim to be is critical. Face matching, specifically 1:1 face match, plays a pivotal role in this process by comparing a live user's face against a photo on their identity document.

React Native, with its cross-platform capabilities, offers an excellent framework for building such applications. However, integrating complex biometric verification can be challenging. This is where Didit's React Native SDK comes in, providing a robust, developer-friendly solution for implementing secure face matching directly within your app.

Understanding 1:1 Face Match for Identity Verification

1:1 Face Match is a core component of modern identity verification. It involves comparing two facial images to determine if they belong to the same person. In the context of identity verification, this typically means comparing a real-time selfie or video of a user with the portrait image extracted from their government-issued ID document (e.g., passport, driver's license). The goal is to confirm that the person presenting the document is indeed the document's rightful owner, thereby preventing impersonation and synthetic identity fraud.

Didit's 1:1 Face Match technology goes beyond simple image comparison. It integrates with advanced liveness detection to ensure the user is physically present and not using a spoofing attempt like a photo, video, or deepfake. The process generates a similarity score, indicating the likelihood that the two faces match. This score, combined with configurable thresholds, allows businesses to automate verification decisions or flag suspicious cases for manual review.

Crucially, Didit's solution provides detailed reports, including similarity scores and potential warnings such as LOW_FACE_MATCH_SIMILARITY or NO_REFERENCE_IMAGE, giving you granular control and insight into each verification attempt. For enhanced security, the URLs for face match images are temporary and expire after 60 minutes, minimizing biometric data retention risks.

Integrating Didit's React Native SDK for Face Matching

Integrating Didit's identity verification capabilities into your React Native application is streamlined thanks to our comprehensive SDK. The SDK is designed to provide a seamless user experience, optimal performance, and full access to device capabilities, including NFC for ePassport/eID verification and advanced camera controls for liveness detection.

Installation and Setup

Didit's React Native SDK supports React Native 0.76+ (New Architecture / TurboModules), Node.js 20+, TypeScript 5+, iOS 13.0+ (NFC requires iOS 15+), and Android API 23+ (Android 6.0). For Expo users, installation is simple:

npx expo install @didit-protocol/sdk-react-native

Then, add the plugin to your app.json:

{
  "expo": {
    "plugins": ["@didit-protocol/sdk-react-native"]
  }
}

For React Native CLI projects, you can install via npm:

npm install @didit-protocol/sdk-react-native

And configure your iOS Podfile and Android settings.gradle as specified in the Didit documentation to ensure proper linking of native dependencies. The SDK handles the complexities of camera permissions, NFC reading, and liveness detection out of the box, ensuring a smooth integration process.

Performing a Face Match Session

Once installed, initiating a verification session that includes face matching involves a few steps. Your backend server will first create a verification session with Didit. The Didit React Native SDK then orchestrates the capture of the user's ID document, passive and active liveness checks, and the real-time selfie needed for the 1:1 face match. The SDK guides the user through the process with intuitive prompts, ensuring high-quality captures.

Upon completion, the SDK securely transmits the collected data to Didit's platform for processing. Didit's AI-native engine then performs the 1:1 face match, comparing the extracted ID photo with the live selfie, alongside other checks like ID Verification. The result, including a similarity score and any warnings, is then relayed back to your backend.

Handling Face Match Results and Warnings

Didit's Face Match API returns a detailed report, providing critical information to inform your verification decisions. The core of this report is the face_match object, which includes a status (e.g., 'Approved', 'Rejected', 'In Review'), a numerical score (ranging from 0-100 indicating similarity), and a list of any warnings.

Understanding and configuring how to handle these warnings is crucial for a robust identity verification system. Didit offers configurable settings for various verification issues, allowing you to define review and decline thresholds. For instance, you can set a 'review threshold' where sessions with face match scores below a certain percentage are flagged for manual review, and a 'decline threshold' for scores below which sessions are automatically rejected.

Common warnings include LOW_FACE_MATCH_SIMILARITY, indicating that the facial features don't closely match, and NO_REFERENCE_IMAGE, meaning a reference image was unavailable. Didit's modular architecture allows you to tailor these responses to your specific risk appetite and compliance needs. By leveraging these detailed reports, you can build sophisticated workflows that balance user experience with stringent security requirements.

How Didit Helps

Didit is the AI-native, developer-first identity platform that simplifies the integration of advanced identity verification into any application, including those built with React Native. Our modular architecture allows you to compose verification checks like 1:1 Face Match, Passive & Active Liveness, and ID Verification as needed, ensuring a tailored and efficient solution.

With Didit, you benefit from a Core KYC tier with pay-per-use pricing, making enterprise-grade identity verification accessible without upfront costs or setup fees. Our AI-native approach ensures high accuracy and fraud detection capabilities, while our developer-first philosophy provides clean APIs, instant sandboxes, and comprehensive documentation for quick integration. Didit's React Native SDK further enhances this by offering an optimized camera experience, NFC verification for ePassports/eIDs, and liveness detection out of the box, delivering the best possible user experience and security for your mobile users.

Ready to Get Started?

Ready to see Didit in action? Get a free demo today.

Start verifying identities for free with Didit's free tier.

Try it

Try this in the sandbox

Run the check this guide describes, free.

ID Verification

The product this post is about, taken from its topic. Run it free in the sandbox.

$0.15 per checkStart free

Author

Alejandro Rosas

Co-founder and CTO

Alejandro Rosas

Alejandro Rosas

Co-founder and CTO

About Didit

Questions

Blog questions

Who writes the Didit blog?
The Didit team. Guides reviewed by Alberto Rosas, co-founder and CEO, carry his byline. The rest are published as Didit.
Which topics does the blog cover?
Eight topics: ID verification, business verification (KYB), AML, sanctions and compliance, fraud prevention, transaction monitoring and crypto, country guides, agents and developers, and product updates.
Is the blog available in my language?
Yes, in 15 languages: English, Spanish, French, German, Brazilian and European Portuguese, Catalan, Russian, Arabic, Chinese, Japanese, Hindi, Indonesian, Korean and Swahili. Not every post is translated, so each language shows the posts it has.
Where do I find product updates?
In the changelog at /changelog/ and under the Product updates topic.
Are these posts legal advice?
No. Regulation posts explain rules; your legal team decides how they apply.
How do I find posts on one topic?
Open one of the eight topics, or search the blog.
Are posts dated?
Yes. Every post shows when it was published and when it was last updated.
Do posts link to the docs?
Developer posts link to the matching page on docs.didit.me and to the API reference.
Is the blog the same as the docs?
No. The blog explains rules, markets and product changes for a general reader, while docs.didit.me holds the integration guides and the API reference. Developer posts link the matching docs page and the API reference they describe.

Compliance built in

Audited, certified and attested.

We hold the certifications and build each country's rules into your flows, so you can launch anywhere without worrying. Security and Compliance center

  • Regulation encoded into your flows

    Tell us what you do and where. Didit lists the rules that apply to you, with sources, and builds the checks each country needs into one workflow.

  • Ready for AMLR

    Every requirement of the new EU anti-money laundering rules, from checking customers to human review, is already covered by a Didit check.

  • Tested in Spain's Treasury sandbox

    Spain's Treasury published its supervised sandbox report on Didit's NFC plus active liveness onboarding; SEPBLAC took part and valued the added measures positively.

  • Audited, not self-declared

    iBeta Level 1 and Level 2. Liveness tested under ISO/IEC 30107-3.

Compliance assistant

Your obligations · 3 regions

EU · AMLRCustomer due diligence, human reviewCovered
Illinois, Texas, ColoradoExplicit biometric consentCovered
Germany · Youth protectionVerified adults only (JMStV)Covered
Workflow checked. Every obligation is met
  • SOC 2 Type 2
  • ISO 27001
  • iBeta Level 1 and Level 2
  • EU regulator attestation
  • FSM youth protection
  • GDPR
  • EBA remote onboarding
  • MiCA compatible
  • FIDO Alliance member
  • AMLREU AML Regulation ready

Integration · Didit MCP

Run Didit from your own AI agent

Connect Didit to Claude, Cursor, VS Code or ChatGPT and just ask in plain words. Your agent can do anything you can do in the console, with the same permissions you have.

Add to ClaudeChatGPT
Didit Academy · Lesson 04 · Use Didit with MCP
  • Build workflowsDescribe the checks you need. The agent creates and publishes the flow.
  • Run investigationsAsk why a session was declined, review cases, search people and companies.
  • Change rulesCreate payment rules, test them on past data and switch them on.
  • Pull reportsAsk for numbers, exports or the audit log.

Verify your first user today.

Start free

Free sandbox. Credit applies to work-email sign-ups.