Customize your Flow integration
Last updated: October 14, 2026
After you've integrated Flow, you can customize the colors, fonts, and borders of the various UI elements to match your website design.
To customize the properties:
- Create an
appearanceobject and include the color, font, or border keys you want to customize, along with their values. For example:
1const appearance = {2colorAction: '#5E48FC',3colorBackground: '#0A0A0C',4colorBorder: '#68686C',5colorDisabled: '#64646E',6colorError: '#FF3300',7colorFormBackground: '#1F1F1F',8colorFormBorder: '#1F1F1F',9colorInverse: '#F9F9FB',10colorOutline: '#ADA4EC',11colorPrimary: '#F9F9FB',12colorSecondary: '#828388',13colorSuccess: '#2ECC71',14button: {15fontFamily: '"Roboto Mono", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif',16fontSize: '16px',17fontWeight: 700,18letterSpacing: 0,19lineHeight: '24px',20},21footnote: {22fontFamily: '"PT Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif',23fontSize: '14px',24fontWeight: 400,25letterSpacing: 0,26lineHeight: '20px',27},28label: {29fontFamily: '"Roboto Mono", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif',30fontSize: '14px',31fontWeight: 400,32letterSpacing: 0,33lineHeight: '20px',34},35subheading: {36fontFamily: '"Roboto Mono", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", "Noto Sans", "Liberation Sans", Arial, sans-serif',37fontSize: '16px',38fontWeight: 700,39letterSpacing: 0,40lineHeight: '24px',41},42borderRadius: ['8px', '8px'],43};
- Create a
componentOptionsobject and include the customization options for the individual components you want to modify:
1{2componentOptions: {3card: {4data: {5cardholderName: 'Jia Tsang'6},7displayCardholderName: 'top'8}9}10}
- Pass the
appearanceandcomponentOptionsobjects when you create the instance ofCheckoutWebComponents.
1const checkout = await CheckoutWebComponents({2paymentSession,3publicKey,4environment: 'sandbox',5appearance,6componentOptions,7});
You can customize the color of the following UI elements:
To customize an element, provide a CSS color value to any of the following keys:
| Key | Format |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
To make Flow use the same fonts as your website, use web fonts and set the font family names in the fontFamily key.
Information
Custom web fonts are not supported in card detail input fields. To ensure consistency across all UI elements, provide web safe fonts and default fonts as a fallback.
Use the following properties to modify the fonts for specific UI elements:
| Property | Type |
|---|---|
|
|
|
|
|
|
|
|
|
|
You can modify the following sub-properties of each font property:
| Property | Type | Example |
|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Information
To change the text displayed in the UI, such as the text on the payment button, add a custom translation.
Use the following properties to modify the borders for specific UI elements:
| Property | Type | Example |
|---|---|---|
| An |
|
You can set the border width and color of each side of an input independently. The following optional tokens override the uniform borderWidth and colorFormBorder values for that side:
| Token | Type | Example |
|---|---|---|
| CSS length |
|
| CSS length |
|
| CSS length |
|
| CSS length |
|
| CSS color |
|
| CSS color |
|
| CSS color |
|
| CSS color |
|
These tokens apply to text inputs (such as billing address fields and cardholder name), secure card fields (card number, expiry date, and CVV), and selects (such as the country picker). They do not apply to checkboxes, radio buttons, the one-time-passcode field, or the open dropdown list.
Any token you leave unset uses the uniform default, so existing integrations look the same.
To remove a border side, set its width token to '0px'. Avoid matching the border color to the page background instead, because the border still takes up layout space, breaks on non-solid backgrounds, and reappears on focus and error states.
In error and disabled states, Flow recolors every visible side. Zero-width sides stay hidden.
The following example produces an underline-style form with a bottom border only:
1const checkout = await CheckoutWebComponents({2publicKey,3paymentSession,4appearance: {5borderWidthTop: '0px',6borderWidthRight: '0px',7borderWidthLeft: '0px',8borderWidthBottom: '1px',9colorFormBorderBottom: '#000000',10},11});
You can have the card component collect the customer's billing address. Use the following componentOptions.card options:
capturedBillingAddressFields– The billing address fields to collect.requiredBillingAddressFields– The collected fields the customer must complete.
For the full list of options, see the CheckoutWebComponents reference.
Collect the country and zip code, and require both:
1const componentOptions = {2card: {3capturedBillingAddressFields: ['country', 'zip'],4requiredBillingAddressFields: ['country', 'zip']5}6};
Collect the country and zip code, and require only the country:
1const componentOptions = {2card: {3capturedBillingAddressFields: ['country', 'zip'],4requiredBillingAddressFields: ['country']5}6};
Collect the full address, and require every field:
1const componentOptions = {2card: {3capturedBillingAddressFields: ['country', 'address_line1', 'address_line2', 'city', 'state', 'zip'],4requiredBillingAddressFields: ['country', 'address_line1', 'address_line2', 'city', 'state', 'zip']5}6};
Collect the full address, and require only the country, first address line, and zip code:
1const componentOptions = {2card: {3capturedBillingAddressFields: ['country', 'address_line1', 'address_line2', 'city', 'state', 'zip'],4requiredBillingAddressFields: ['country', 'address_line1', 'zip']5}6};