Link in the Card Element
Enable checkout using Link with the Card Element.
Caution
Stripe no longer recommends using the Card Element as part of your Web Elements integration. To integrate Link, use one of our preferred Elements: the Link Authentication Element, Express Checkout Element, or Payment Element.
Use Link in the Card Element to save and autofill payment information for your customers, so they don’t need to enter their payment details manually.
The Card Element can take on two forms: a single line Card Element or split Elements (like Card Number, Expiry, and CVC). When referring to the Card Element, the following information applies to both forms.
The Link flow
Link enablement
Link is supported in the Card Element globally for all businesses with granted access and doesn’t require additional fees or code changes (see note below for details). Link is fully compatible with the other features you receive from card payments.
Stripe automatically enables Link in the Card Element. You can disable Link for all instances of the Card Element in your Payment Method settings. In the Link section, click the overflow menu () next to the Link row, and disable Link in Card Element. This setting applies to both forms of the Card Element. You can also set the disableLink parameter to true
to disable Link in the Card Element. You only need to use one of these controls to hide Link in the Card Element.
Link isn’t visible in the Card Element if:
The parent container that the Card Element is mounted in is too short in height or narrow in width to display the Link button. Typically, we require a minimum width of 350px and height of 28px. However, other factors such as font size, locale, placeholder text, and card icon visibility can also affect these requirements.
The Card Element is displayed on a browser that doesn’t support pop-ups, including in-app browsers. View information about supported browsers.
The Cross-Origin-Opener-Policy is set to
same-origin
. The Link pop-up must communicate with the page that opened it, so Link in the Card Element isn’t compatible with configurations that block this communication.
Note
We’re releasing Link in the Card Element in phases. Link for the single line Card Element was released in 2023, followed by Link in split Elements in late 2023 and early 2024. Only accounts with granted access can see Link in the Card Element in their Payment Method settings or use Link in production or test mode. Link isn’t currently supported for Stripe accounts based in India.
Use the Card Element and Payment Request Button
You can also use Link with the Payment Request Button. Link in the Card Element operates independently from Link in the Payment Request button. If you use both the Payment Request Button and the Card Element, Link might appear in both during checkout. For more information on when Link appears in the Payment Request Button, see Link in the Payment Request Button.
Link and Connect platforms
Link is automatically available to any accounts that access the Card Element through a Connect platform integration. Depending on a platform’s integration, a platform may be able to give its users (connected accounts) the ability to customize their own Link settings in the Dashboard:
Eligibility requirements for connected platforms
If the following conditions are all met by your platform, then your connected accounts can manage their Link settings directly in their own Dashboard.
You use direct charges.
You create and charge payment methods on your connected accounts.
Your connected accounts have access to the full Stripe Dashboard.
To set the default state for all connected accounts on your platform:
Click Edit settings under Your connected accounts in Payment Method settings.
Navigate to Link in the Card Element in the Link section.
Ineligible connected platforms
In the following cases, Link is controlled by your platform account settings, and your connected accounts can’t customize their Link settings for payments processed through your platform:
You create payment methods on your platform and then clone payment methods to your connected accounts.
You use destination charges or separate charges and transfers.
Your connected accounts don’t have access to the full Stripe Dashboard.
To manage your platform account settings:
Click Edit settings under Your Account in Payment Method settings.
Navigate to Link in the Card Element in the Link section. If you want to turn Link off for only specific connected accounts, you can use the disableLink parameter.
Payment processing for connected accounts
If your platform offers you the ability to customize your Link settings for platform payments, then you can manage your Link in Card Element settings within Payment Method settings by selecting your platform from the dropdown menu at the top of the page.
If your platform isn’t able to offer you settings customization, then the platform determines Link’s availability for all payments processed through the platform, and you won’t have settings control for platform payments in your Dashboard.
For payments you process without a platform, you can manage Link in your Payment Method settings by selecting “no platform” from the dropdown menu at the top of the page.
Test Link in the Card Element
Caution
Don’t store real user data in test mode Link accounts. Treat them as if they’re publicly available, because these test accounts are associated with your publishable key.
Link works with the following browsers:
Chrome, Chrome Mobile, and Microsoft Edge.
Safari on desktop and iOS (last 3 major versions).
Link is available in both production and test mode. You can create test mode Link accounts using any valid email address. The following table shows the fixed one-time passcode values that Stripe accepts for authenticating Link test mode accounts:
Value | Outcome |
---|---|
Any other 6 digits not listed below | Success |
000001 | Error, code invalid |
000002 | Error, code expired |
000003 | Error, max attempts exceeded |
Enabling Link in test mode presents Link on all Card Element test mode sessions that meet the enablement requirements. In production, Link’s visibility might vary to maximize Link’s conversion benefits in each checkout session.