Link React Native SDK
Reference for integrating with the Link React Native SDK
This guide covers the latest major version of the Link React Native SDK, which is version 11.x.x. Beginning January 1, 2024, all integrations must use version 9.0.1 or later in order to maintain support for Chase OAuth flows on iOS, with a hard cutoff to occur by mid-January. This represents an extension of the original September 30, 2023 deadline. If you are using the 7.x or 8.x version of the SDK, the only migration requirement for version 9.x is to make sure you are using a compatible version of the iOS SDK (4.1.0 or later) and Xcode 14.
For information on migrating from 9.x to 10.x, see Upgrading.
Overview
Prefer to learn with code examples? A GitHub repo showing a working example Link implementation is available for this topic.
To get started with Plaid Link for React Native youʼll want to sign up for free API keys through the Plaid Dashboard.

Requirements
- React Native Version
0.66.0or higher - See the Android setup guide and iOS setup guide for platform-specific requirements
New versions of the React Native SDK are released frequently, at least once every few months. Major releases occur annually. You should keep your version up-to-date to provide the best Plaid Link experience in your application.
Version Compatibility
| React Native SDK | Android SDK | iOS SDK | Status |
|---|---|---|---|
| 10.x.x | 3.10.1+ | >=4.1.0 | Active, supports Xcode 14 |
| 9.x.x | 3.10.1+ | >=4.1.0 | Deprecated, supports Xcode 14 |
| 8.x.x | 3.10.1+ | >=3.1.0 | Deprecated, supports Xcode 14 |
| 7.x.x | 3.2.0+ | >=2.0.7 | Deprecated, supports Xcode <=13 |
| 6.x.x | 3.0.0-3.1.0 | >=2.0.1 | Deprecated |
| 5.x.x | 2.1.0-2.2.0 | >=1.1.34 | Deprecated |
| 4.x.x | 2.0.0 | <=1.1.33 | Deprecated |
| 3.x.x | 1.x.x | <=1.1.33 | Deprecated |
| 2.x.x | 0.3.x | <=1.1.27 | Deprecated |
| 1.x.x | < 0.3.x | <=1.1.24 | Deprecated |
Getting Started
Installing the SDK
In your react-native project directory, run:
1npm install --save react-native-plaid-link-sdkNext Steps
- To set up the SDK for use in your Android application, see the Android Set Up guide.
- To set up the SDK for use in your iOS application see the iOS Set Up guide.
- For a sample app that demonstrates a minimal integration with the React Native Plaid Link SDK, see the Tiny Quickstart (React Native).
Opening Link
Before you can open Link, you need to first create a link_token. A link_token can be configured for
different Link flows and is used to control much of Link's behavior. To see how to create a new
link_token, see the API Reference entry for /link/token/create.
If your React Native application will be used on Android, the link/token/create call should include the android_package_name parameter.
Each time you open Link, you will need to get a new link_token from your server.
PlaidLink
PlaidLink is the the React component used to open Link from a React Native application. PlaidLink renders a Pressable component, which wraps the component you provide and intercepts onPress events to open Link.
plaidLinktokenConfigtokenlink_token to be used to authenticate your app with Link. The link_token is created by calling /link/token/create and is a short lived, one-time use token that should be unique for each Link session. In addition to the primary flow, a link_token can be configured to launch Link in update mode. See the /link/token/create endpoint for a full list of configurations.logLevelDEBUG, INFO, WARN, ERRORextraParamschildren1<PlaidLink2 tokenConfig={{3 token: '#GENERATED_LINK_TOKEN#',4 }}5 onSuccess={(success: LinkSuccess) => {6 console.log(success);7 }}8 onExit={(exit: LinkExit) => {9 console.log(exit);10 }}11>12 <Text>Add Account</Text>13</PlaidLink>onSuccess
The method is called when a user successfully links an Item. The onSuccess handler returns a LinkConnection class that includes the public_token, and additional Link metadata in the form of a LinkConnectionMetadata class.
publicTokenmetadataaccountsaccounts will only include selected accounts.idaccount_idnamemasktypesubtypeverification_statuspending_automatic _verificationpending_manual _verificationautomatically_verifiedmanually_verifiedverification_expiredverification_failednullinstitutionnull.linkSessionIdmetadataJson1const onSuccess = (success: LinkSuccess) => {2 fetch('https://yourserver.com/exchange_public_token', {3 method: 'POST',4 headers: {5 "Content-Type": "application/json",6 },7 body: JSON.Stringify({8 publicToken: linkSuccess.publicToken,9 accounts: linkSuccess.metadata.accounts,10 institution: linkSuccess.metadata.institution,11 linkSessionId: linkSuccess.metadata.linkSessionId,12 }),13 });14};onExit
The onExit handler is called when a user exits Link without successfully linking an Item, or when an error occurs during Link initialization. The PlaidError returned from the onExit handler is meant to help you guide your users after they have exited Link. We recommend storing the error and metadata information server-side in a way that can be associated with the user. You’ll also need to include this and any other relevant info in Plaid Support requests for the user.
errorerror will be null.displayMessagenull if the error is not related to user action. This may change over time and is not safe for programmatic use.errorCodeerrorType has a specific set of errorCodes. A code of 499 indicates a client-side exception.errorTypeerrorMessageerrorJsonmetadatalinkSessionIdinstitutionnull.statusrequires_questionsrequires_selectionsrequires_recaptcharequires_codechoose_devicerequires_credentialsrequires_account _selectionrequires_oauthinstitution_not_foundinstitution_not _supportedunknownrequestIdmetadataJson1const onExit = (linkExit: LinkExit) => {2 supportHandler.report({3 error: linkExit.error,4 institution: linkExit.metadata.institution,5 linkSessionId: linkExit.metadata.linkSessionId,6 requestId: linkExitlinkExit.metadata.requestId,7 status: linkExit.metadata.status,8 });9};onEvent
The React Native Plaid module emits onEvent events throughout the account linking process.
To receive these events use the usePlaidEmitter hook.
The onEvent callback is called at certain points in the Link flow. Unlike the handlers for onSuccess and onExit, the onEvent handler is initialized as a global lambda passed to the Plaid class. OPEN events will be sent immediately upon Link’s opening, and remaining events will be sent by the time onSuccess or onExit is called. If you need the exact time when an event happened, use the timestamp property.
The following onEvent callbacks are stable, which means that they will not be deprecated or changed: OPEN, EXIT, HANDOFF, SELECT_INSTITUTION, ERROR, BANK_INCOME_INSIGHTS_COMPLETED, IDENTITY_VERIFICATION_PASS_SESSION, IDENTITY_VERIFICATION_FAIL_SESSION. The remaining callback events are informational and subject to change.
eventNameBANK_INCOME_INSIGHTS _COMPLETEDCLOSE_OAUTHCONNECT_NEW _INSTITUTIONERRORerror_code metadata.FAIL_OAUTHHANDOFFIDENTITY_VERIFICATION _START_STEPview_name.IDENTITY_VERIFICATION _PASS_STEPview_name.IDENTITY_VERIFICATION _FAIL_STEPview_name.IDENTITY_VERIFICATION _PENDING_REVIEW_STEPIDENTITY_VERIFICATION _CREATE_SESSIONIDENTITY_VERIFICATION _RESUME_SESSIONIDENTITY_VERIFICATION _PASS_SESSIONIDENTITY_VERIFICATION _PENDING_REVIEW _SESSIONIDENTITY_VERIFICATION _FAIL_SESSIONIDENTITY_VERIFICATION _OPEN_UIIDENTITY_VERIFICATION _RESUME_UIIDENTITY_VERIFICATION _CLOSE_UIMATCHED_SELECT _INSTITUTIONrouting_number was provided when calling /link/token/create. To distinguish between the two scenarios, see metadata.matchReason.MATCHED_SELECT_VERIFY _METHODOPENOPEN_MY_PLAIDOPEN_OAUTHSEARCH_INSTITUTIONSELECT_BRANDSELECT_BRAND event is only emitted for large financial institutions with multiple online banking portals.SELECT_DEGRADED _INSTITUTIONDEGRADED health status and was shown a corresponding message.SELECT_DOWN _INSTITUTIONDOWN health status and was shown a corresponding message.SELECT_FILTERED _INSTITUTIONSELECT_INSTITUTIONSKIP_SUBMIT_PHONESUBMIT_ACCOUNT_NUMBERaccount_number_mask metadata to indicate the mask of the account number the user provided.SUBMIT_CREDENTIALSSUBMIT_MFASUBMIT_PHONESUBMIT_ROUTING_NUMBERrouting_number metadata to indicate user's routing number.TRANSITION_VIEWTRANSITION_VIEW event indicates that the user has moved from one view to the next.VERIFY_PHONEVIEW_DATA_TYPESUNKNOWNUNKNOWN event indicates that the event is not handled by the current version of the SDK.metadatasubmitAccountNumberaccount_number_mask is empty. Emitted by SUBMIT_ACCOUNT_NUMBER.errorCodeERROR, EXIT.errorMessageERROR, EXIT.errorTypeERROR, EXIT.exitStatusEXIT.institutionIdinstitutionNameinstitutionSearchQuerySEARCH_INSTITUTION.isUpdateModeOPEN.matchReasonreturning_user or routing_number if emitted by: MATCHED_SELECT_INSTITUTION.
Otherwise, this will be SAVED_INSTITUTION or AUTO_SELECT_SAVED_INSTITUTION if emitted by: SELECT_INSTITUTION.routingNumberSUBMIT_ROUTING_NUMBER.linkSessionIdlinkSessionId is a unique identifier for a single session of Link. It's always available and will stay constant throughout the flow. Emitted by: all events.mfaTypecode device questions selections. Emitted by: SUBMIT_MFA and TRANSITION_VIEW when view_name is MFA.requestIdselectionselection is used to describe selected verification method, then possible values are phoneotp or password; if selection is used to describe the selected Auth Type Select flow, then possible values are flow_type_manual or flow_type_instant. Emitted by: MATCHED_SELECT_VERIFY_METHOD and SELECT_AUTH_TYPE.timestamp2017-09-14T14:42:19.350Z. Emitted by: all events.viewNameTRANSITION_VIEW.ACCEPT_TOSCONNECTEDCONSENTCREDENTIALDATA_TRANSPARENCYDATA_TRANSPARENCY _CONSENTDOCUMENTARY _VERIFICATIONERROREXITKYC_CHECKLOADINGMATCHED_CONSENTMATCHED_CREDENTIALMATCHED_MFAMFANUMBERSOAUTHRECAPTCHARISK_CHECKSCREENINGSELECT_ACCOUNTSELECT_AUTH_TYPESELECT_BRANDSELECT_INSTITUTIONSELECT_SAVED_ACCOUNTSELECT_SAVED _INSTITUTIONSELFIE_CHECKSUBMIT_PHONEUPLOAD_DOCUMENTSVERIFY_PHONEVERIFY_SMS1usePlaidEmitter((event) => {2 console.log(event);3});OAuth
Using Plaid Link with an OAuth flow requires some additional setup instructions. For details, see the OAuth guide.
Upgrading
- Version 11.x contains several breaking changes from previous major versions. For details, see the migration guide on GitHub.
- When upgrading from 9.x to 10.x or later, you should remove any invocation of
useDeepLinkRedirectoron iOS, as it has been removed from the SDK, since it is no longer required for handling Universal Links. You must make sure you are using a compatible version of React Native (0.66.0 or higher) and the Plaid iOS SDK (see the version compatibility chart on GitHub). - The only difference between version 7.x and 8.x is that 8.x adds support for Xcode 14. No code changes are required to upgrade from 7.x to 8.x, although you must convert to an Xcode 14 toolchain.
- No code changes are required to upgrade from 8.x to 9.x, although you must make sure you are using a compatible version of the Plaid iOS SDK (4.1.0 or higher).
The latest version of the SDK is available from GitHub. SDK versions are supported for two years; with each major SDK release, Plaid will stop officially supporting any previous SDK versions that are more than two years old. While these older versions are expected to continue to work without disruption, Plaid will not provide assistance with unsupported SDK versions.