# CustomTabsIntent.Builder

Artifact: [androidx.browser:browser](https://developer.android.com/jetpack/androidx/releases/browser) [View Source](https://cs.android.com/search?q=file:androidx/browser/customtabs/CustomTabsIntent.java+class:androidx.browser.customtabs.CustomTabsIntent.Builder) Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

*** ** * ** ***


```
public final class CustomTabsIntent.Builder
```

<br />

*** ** * ** ***

Builder class for `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent` objects.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#Builder()()` Creates a `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` object associated with no `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession`. |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#Builder(androidx.browser.customtabs.CustomTabsSession)(@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession session)` Creates a `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` object associated with a given `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession`. |

| ### Public methods |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `@https://developer.android.com/reference/androidx/browser/customtabs/ExperimentalCustomContentAction https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#addCustomContentAction(androidx.browser.customtabs.CustomContentAction)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomContentAction action)` Adds a custom content action that can be invoked by the user on specific content types (image or link) within the Custom Tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `[addDefaultShareMenuItem](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#addDefaultShareMenuItem())()` **This method is deprecated.** Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setShareState(int)` instead. <br /> |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#addMenuItem(java.lang.String,android.app.PendingIntent)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html label, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent)` Adds a menu item. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `[addToolbarItem](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#addToolbarItem(int,android.graphics.Bitmap,java.lang.String,android.app.PendingIntent))( int id, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/graphics/Bitmap.html icon, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html description, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent )` **This method is deprecated.** Use CustomTabsIntent.Builder#setSecondaryToolbarViews(RemoteViews, int\[\], PendingIntent). <br /> |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#build()()` Combines all the options that have been set and returns a new `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent` object. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `[enableUrlBarHiding](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#enableUrlBarHiding())()` **This method is deprecated.** Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setUrlBarHidingEnabled(boolean)` instead. <br /> |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActionButton(android.graphics.Bitmap,java.lang.String,android.app.PendingIntent)( @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/graphics/Bitmap.html icon, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html description, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent )` Sets the action button that is displayed in the Toolbar with default tinting behavior. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActionButton(android.graphics.Bitmap,java.lang.String,android.app.PendingIntent,boolean)( @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/graphics/Bitmap.html icon, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html description, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent, boolean shouldTint )` Sets the action button that is displayed in the Toolbar. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActivitySideSheetBreakpointDp(int)(@https://developer.android.com/reference/androidx/annotation/Dimension(unit = 0) int breakpointDp)` Sets the Custom Tab Activity's transition breakpoint in DP. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActivitySideSheetDecorationType(int)(int decorationType)` Sets the Custom Tab Activity's decoration type that will be displayed when it is acting as a side sheet. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActivitySideSheetMaximizationEnabled(boolean)(boolean enabled)` Enables or disables the maximization button for when the Custom Tab Activity is acting as a side sheet. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActivitySideSheetPosition(int)(int position)` Sets the Custom Tab Activity's position when acting as a side sheet. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActivitySideSheetRoundedCornersPosition(int)(int roundedCornersPosition)` Sets the Custom Tab Activity's rounded corners position when it is acting as a side sheet. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setBackgroundInteractionEnabled(boolean)(boolean enabled)` Enables the capability of the interaction with background. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setBookmarksButtonEnabled(boolean)(boolean enabled)` Enables or disables the bookmarks button in the overflow menu. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setCloseButtonEnabled(boolean)(boolean enabled)` Sets whether to enable the close button for custom tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setCloseButtonIcon(android.graphics.Bitmap)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/graphics/Bitmap.html icon)` Sets the Close button icon for the custom tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setCloseButtonPosition(int)(int position)` Sets the position of the close button. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setColorScheme(int)(int colorScheme)` Sets the color scheme that should be applied to the user interface in the custom tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setColorSchemeParams(int,androidx.browser.customtabs.CustomTabColorSchemeParams)( int colorScheme, @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams params )` Sets `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams` for the given color scheme. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams params)` Sets the default `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams`. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `[setDefaultShareMenuItemEnabled](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultShareMenuItemEnabled(boolean))(boolean enabled)` **This method is deprecated.** Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setShareState(int)` instead. <br /> |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDownloadButtonEnabled(boolean)(boolean enabled)` Enables or disables the download button in the overflow menu. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setEphemeralBrowsingEnabled(boolean)(boolean enabled)` Sets whether to enable ephemeral browsing within the Custom Tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setExitAnimations(android.content.Context,int,int)( @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/content/Context.html context, @https://developer.android.com/reference/androidx/annotation/AnimRes int enterResId, @https://developer.android.com/reference/androidx/annotation/AnimRes int exitResId )` Sets the exit animations. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setInitialActivityHeightPx(int)(@https://developer.android.com/reference/androidx/annotation/Dimension(unit = 1) int initialHeightPx)` Sets the Custom Tab Activity's initial height in pixels with default resize behavior. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setInitialActivityHeightPx(int,int)( @https://developer.android.com/reference/androidx/annotation/Dimension(unit = 1) int initialHeightPx, int activityHeightResizeBehavior )` Sets the Custom Tab Activity's initial height in pixels and the desired resize behavior. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setInitialActivityWidthPx(int)(@https://developer.android.com/reference/androidx/annotation/Dimension(unit = 1) int initialWidthPx)` Sets the Custom Tab Activity's initial width in pixels. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `@https://developer.android.com/reference/androidx/browser/customtabs/ExperimentalInitialNavigationCanLeaveBrowser https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setInitialNavigationAllowedToLeaveBrowser(boolean)(boolean enabled)` Allows the Custom Tab to forward the initial URL sent to the Custom Tab to the default handling app for that URL instead of loading it (including following any redirects) in the Custom Tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setInstantAppsEnabled(boolean)(boolean enabled)` Sets whether Instant Apps is enabled for this Custom Tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `[setNavigationBarColor](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setNavigationBarColor(int))(@https://developer.android.com/reference/androidx/annotation/ColorInt int color)` **This method is deprecated.** Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)` instead. <br /> |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `[setNavigationBarDividerColor](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setNavigationBarDividerColor(int))(@https://developer.android.com/reference/androidx/annotation/ColorInt int color)` **This method is deprecated.** Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)` instead. <br /> |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setNetwork(android.net.Network)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/net/Network.html network)` Sets the target network `https://developer.android.com/reference/android/net/Network.html` to bind when launching a custom tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setOpenInBrowserButtonState(int)(int openInBrowserState)` Sets the state for the Open in Browser button in the toolbar for this Custom Tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setPendingSession(androidx.browser.customtabs.CustomTabsSession.PendingSession)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession.PendingSession session)` Associates the `https://developer.android.com/reference/android/content/Intent.html` with the given `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession.PendingSession`. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `[setSecondaryToolbarColor](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setSecondaryToolbarColor(int))(@https://developer.android.com/reference/androidx/annotation/ColorInt int color)` **This method is deprecated.** Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)` instead. <br /> |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setSecondaryToolbarSwipeUpGesture(android.app.PendingIntent)(@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent)` Sets the `https://developer.android.com/reference/android/app/PendingIntent.html` to be sent when the user swipes up from the secondary (bottom) toolbar. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setSecondaryToolbarViews(android.widget.RemoteViews,int[],android.app.PendingIntent)( @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/widget/RemoteViews.html remoteViews, @https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html int[] clickableIDs, @https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent )` Sets the remote views displayed in the secondary toolbar in a custom tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setSendToExternalDefaultHandlerEnabled(boolean)(boolean enabled)` Enables sending any redirects off of the initial URL sent to the Custom Tab to default handling apps. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setSession(androidx.browser.customtabs.CustomTabsSession)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession session)` Associates the `https://developer.android.com/reference/android/content/Intent.html` with the given `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession`. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setShareIdentityEnabled(boolean)(boolean enabled)` Allow Custom Tabs to obtain the caller's identity i.e. package name. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setShareState(int)(int shareState)` Sets the share state that should be applied to the custom tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setShowTitle(boolean)(boolean showTitle)` Sets whether the title should be shown in the custom tab. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setStartAnimations(android.content.Context,int,int)( @https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/content/Context.html context, @https://developer.android.com/reference/androidx/annotation/AnimRes int enterResId, @https://developer.android.com/reference/androidx/annotation/AnimRes int exitResId )` Sets the start animations. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `[setToolbarColor](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setToolbarColor(int))(@https://developer.android.com/reference/androidx/annotation/ColorInt int color)` **This method is deprecated.** Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)` instead. <br /> |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setToolbarCornerRadiusDp(int)(@https://developer.android.com/reference/androidx/annotation/Dimension(unit = 0) int cornerRadiusDp)` Sets the toolbar's top corner radii in dp. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setTranslateLocale(java.util.Locale)(@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/util/Locale.html locale)` Specifies the target locale the Translate UI should be triggered with. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setUrlBarHidingEnabled(boolean)(boolean enabled)` Set whether the url bar should hide as the user scrolls down on the page. |

## Public constructors

### Builder

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public Builder()
```

Creates a `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` object associated with no `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession`.

### Builder

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public Builder(@Nullable CustomTabsSession session)
```

Creates a `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` object associated with a given `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession`. Guarantees that the `https://developer.android.com/reference/android/content/Intent.html` will be sent to the same component as the one the session is associated with.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession session` | The session to associate this Builder with. |

## Public methods

### addCustomContentAction

Added in [1.9.0](https://developer.android.com/jetpack/androidx/releases/browser#1.9.0)

```
@ExperimentalCustomContentAction
public @NonNull CustomTabsIntent.Builder addCustomContentAction(@NonNull CustomContentAction action)
```

Adds a custom content action that can be invoked by the user on specific content types (image or link) within the Custom Tab.

The number of actions shown to the user is at the browser's discretion. The browser may choose not to display all the actions provided. Additionally, priority will be based on the order the actions were added, with the earliest added action being given the highest priority.

When the user triggers this action, the browser will send the `https://developer.android.com/reference/androidx/browser/customtabs/CustomContentAction#getPendingIntent()` associated with this action. The `https://developer.android.com/reference/android/content/Intent.html` within the `https://developer.android.com/reference/android/app/PendingIntent.html` will include the current URL of the Custom Tab as its data, `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_TRIGGERED_CUSTOM_CONTENT_ACTION_ID()` with the ID of this action, `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_CLICKED_CONTENT_TARGET_TYPE()` with the type of content interacted with, and potentially other contextual extras (e.g., `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_CONTEXT_IMAGE_URL()`).

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomContentAction action` | The `https://developer.android.com/reference/androidx/browser/customtabs/CustomContentAction` to add. Must not be null. |

| Returns |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder` | This Builder. |

| Throws |
|---|---|
| `https://developer.android.com/reference/java/lang/IllegalArgumentException.html` | if an action with the same ID has already been added. |

### addDefaultShareMenuItem

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0) Deprecated in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder [addDefaultShareMenuItem](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#addDefaultShareMenuItem())()
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setShareState(int)` instead. This will set the share state to `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#SHARE_STATE_ON()`.

Adds a default share item to the menu.

### addMenuItem

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder addMenuItem(@NonNull String label, @NonNull PendingIntent pendingIntent)
```

Adds a menu item.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html label` | Menu label. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent` | Pending intent delivered when the menu item is clicked. |

### addToolbarItem

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0) Deprecated in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder [addToolbarItem](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#addToolbarItem(int,android.graphics.Bitmap,java.lang.String,android.app.PendingIntent))(
    int id,
    @NonNull Bitmap icon,
    @NonNull String description,
    @NonNull PendingIntent pendingIntent
)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Use CustomTabsIntent.Builder#setSecondaryToolbarViews(RemoteViews, int\[\], PendingIntent).

Adds an action button to the custom tab. Multiple buttons can be added via this method. If the given id equals `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#TOOLBAR_ACTION_BUTTON_ID()`, the button will be placed on the toolbar; if the bitmap is too wide, it will be put to the bottom bar instead. If the id is not `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#TOOLBAR_ACTION_BUTTON_ID()`, it will be directly put on secondary toolbar. The maximum number of allowed toolbar items in a single intent is `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#getMaxToolbarItems()`. Throws an `https://developer.android.com/reference/java/lang/IllegalStateException.html` when that number is exceeded per intent.

| Parameters |
|---|---|
| `int id` | The unique id of the action button. This should be non-negative. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/graphics/Bitmap.html icon` | The icon. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html description` | The description for the button. To be used for accessibility. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent` | The pending intent delivered when the button is clicked. |

| Throws |
|---|---|
| `https://developer.android.com/reference/java/lang/IllegalStateException.html` |   |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#getMaxToolbarItems()` |   |

### build

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent build()
```

Combines all the options that have been set and returns a new `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent` object.

### enableUrlBarHiding

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0) Deprecated in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder [enableUrlBarHiding](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#enableUrlBarHiding())()
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setUrlBarHidingEnabled(boolean)` instead.

Enables the url bar to hide as the user scrolls down on the page.

### setActionButton

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setActionButton(
    @NonNull Bitmap icon,
    @NonNull String description,
    @NonNull PendingIntent pendingIntent
)
```

Sets the action button that is displayed in the Toolbar with default tinting behavior.

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActionButton(android.graphics.Bitmap,java.lang.String,android.app.PendingIntent,boolean)` |   |

### setActionButton

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setActionButton(
    @NonNull Bitmap icon,
    @NonNull String description,
    @NonNull PendingIntent pendingIntent,
    boolean shouldTint
)
```

Sets the action button that is displayed in the Toolbar.

This is equivalent to calling `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#addToolbarItem(int,android.graphics.Bitmap,java.lang.String,android.app.PendingIntent)` with `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#TOOLBAR_ACTION_BUTTON_ID()` as id.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/graphics/Bitmap.html icon` | The icon. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/lang/String.html description` | The description for the button. To be used for accessibility. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent` | pending intent delivered when the button is clicked. |
| `boolean shouldTint` | Whether the action button should be tinted.. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#addToolbarItem(int,android.graphics.Bitmap,java.lang.String,android.app.PendingIntent)` |   |

### setActivitySideSheetBreakpointDp

Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/browser#1.8.0)

```
public @NonNull CustomTabsIntent.Builder setActivitySideSheetBreakpointDp(@Dimension(unit = 0) int breakpointDp)
```

Sets the Custom Tab Activity's transition breakpoint in DP.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/Dimension(unit = 0) int breakpointDp` | The Custom Tab Activity's breakpoint in DP. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_ACTIVITY_SIDE_SHEET_BREAKPOINT_DP()` |   |

### setActivitySideSheetDecorationType

Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/browser#1.8.0)

```
public @NonNull CustomTabsIntent.Builder setActivitySideSheetDecorationType(int decorationType)
```

Sets the Custom Tab Activity's decoration type that will be displayed when it is acting as a side sheet.

| Parameters |
|---|---|
| `int decorationType` | The Custom Tab Activity's decoration type. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_ACTIVITY_SIDE_SHEET_DECORATION_TYPE()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_SIDE_SHEET_DECORATION_TYPE_DEFAULT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_SIDE_SHEET_DECORATION_TYPE_NONE()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_SIDE_SHEET_DECORATION_TYPE_SHADOW()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_SIDE_SHEET_DECORATION_TYPE_DIVIDER()` |   |

### setActivitySideSheetMaximizationEnabled

Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/browser#1.8.0)

```
public @NonNull CustomTabsIntent.Builder setActivitySideSheetMaximizationEnabled(boolean enabled)
```

Enables or disables the maximization button for when the Custom Tab Activity is acting as a side sheet. The button is disabled by default.

| Parameters |
|---|---|
| `boolean enabled` | Whether the maximization button is enabled. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_ACTIVITY_SIDE_SHEET_ENABLE_MAXIMIZATION()` |   |

### setActivitySideSheetPosition

Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/browser#1.8.0)

```
public @NonNull CustomTabsIntent.Builder setActivitySideSheetPosition(int position)
```

Sets the Custom Tab Activity's position when acting as a side sheet.

| Parameters |
|---|---|
| `int position` | The Custom Tab Activity's position. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_ACTIVITY_SIDE_SHEET_POSITION()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#CLOSE_BUTTON_POSITION_DEFAULT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#CLOSE_BUTTON_POSITION_START()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#CLOSE_BUTTON_POSITION_END()` |   |

### setActivitySideSheetRoundedCornersPosition

Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/browser#1.8.0)

```
public @NonNull CustomTabsIntent.Builder setActivitySideSheetRoundedCornersPosition(int roundedCornersPosition)
```

Sets the Custom Tab Activity's rounded corners position when it is acting as a side sheet.

| Parameters |
|---|---|
| `int roundedCornersPosition` | The Custom Tab Activity's rounded corners position. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_ACTIVITY_SIDE_SHEET_ROUNDED_CORNERS_POSITION()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_SIDE_SHEET_ROUNDED_CORNERS_POSITION_DEFAULT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_SIDE_SHEET_ROUNDED_CORNERS_POSITION_NONE()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_SIDE_SHEET_ROUNDED_CORNERS_POSITION_TOP()` |   |

### setBackgroundInteractionEnabled

Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/browser#1.7.0)

```
public @NonNull CustomTabsIntent.Builder setBackgroundInteractionEnabled(boolean enabled)
```

Enables the capability of the interaction with background. Enables the interactions with the background app when a Partial Custom Tab is launched.

| Parameters |
|---|---|
| `boolean enabled` | Whether the background interaction is enabled. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_DISABLE_BACKGROUND_INTERACTION()` |   |

### setBookmarksButtonEnabled

Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/browser#1.7.0)

```
public @NonNull CustomTabsIntent.Builder setBookmarksButtonEnabled(boolean enabled)
```

Enables or disables the bookmarks button in the overflow menu. The button is enabled by default.

| Parameters |
|---|---|
| `boolean enabled` | Whether the start button is enabled. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_DISABLE_BOOKMARKS_BUTTON()` |   |

### setCloseButtonEnabled

Added in [1.9.0](https://developer.android.com/jetpack/androidx/releases/browser#1.9.0)

```
public @NonNull CustomTabsIntent.Builder setCloseButtonEnabled(boolean enabled)
```

Sets whether to enable the close button for custom tab. The close button is enabled by default. If the close button is disabled, calls to `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setCloseButtonIcon(android.graphics.Bitmap)` or `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setCloseButtonPosition(int)` have no effect.

| Parameters |
|---|---|
| `boolean enabled` | Whether the close button is enabled. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_CLOSE_BUTTON_ENABLED()` |   |

### setCloseButtonIcon

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setCloseButtonIcon(@NonNull Bitmap icon)
```

Sets the Close button icon for the custom tab. If the close button is disabled (see `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setCloseButtonEnabled(boolean)`), then calling this function has no effect.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/graphics/Bitmap.html icon` | The icon `https://developer.android.com/reference/android/graphics/Bitmap.html` |

### setCloseButtonPosition

Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/browser#1.5.0)

```
public @NonNull CustomTabsIntent.Builder setCloseButtonPosition(int position)
```

Sets the position of the close button. If the close button is disabled (see `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setCloseButtonEnabled(boolean)`), then calling this function has no effect.

| Parameters |
|---|---|
| `int position` | The desired position. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#CLOSE_BUTTON_POSITION_DEFAULT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#CLOSE_BUTTON_POSITION_START()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#CLOSE_BUTTON_POSITION_END()` |   |

### setColorScheme

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setColorScheme(int colorScheme)
```

Sets the color scheme that should be applied to the user interface in the custom tab.

| Parameters |
|---|---|
| `int colorScheme` | Desired color scheme. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#COLOR_SCHEME_SYSTEM()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#COLOR_SCHEME_LIGHT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#COLOR_SCHEME_DARK()` |   |

### setColorSchemeParams

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setColorSchemeParams(
    int colorScheme,
    @NonNull CustomTabColorSchemeParams params
)
```

Sets `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams` for the given color scheme. This allows specifying two different toolbar colors for light and dark schemes. It can be useful if `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#COLOR_SCHEME_SYSTEM()` is set: Custom Tabs will follow the system settings and apply the corresponding `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams` "on the fly" when the settings change. If there is no `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams` for the current scheme, or a particular field of it is null, Custom Tabs will fall back to the defaults provided via `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)`. Example:

```
    CustomTabColorSchemeParams darkParams = new CustomTabColorSchemeParams.Builder()
            .setToolbarColor(darkColor)
            .build();
    CustomTabColorSchemeParams otherParams = new CustomTabColorSchemeParams.Builder()
            .setNavigationBarColor(otherColor)
            .build();
    CustomTabIntent intent = new CustomTabIntent.Builder()
            .setColorScheme(COLOR_SCHEME_SYSTEM)
            .setColorSchemeParams(COLOR_SCHEME_DARK, darkParams)
            .setDefaultColorSchemeParams(otherParams)
            .build();
```

| Parameters |
|---|---|
| `int colorScheme` | A constant representing a color scheme (see `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setColorScheme(int)`). It should not be `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#COLOR_SCHEME_SYSTEM()`, because that represents a behavior rather than a particular color scheme. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams params` | An instance of `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams`. |

### setDefaultColorSchemeParams

Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder setDefaultColorSchemeParams(@NonNull CustomTabColorSchemeParams params)
```

Sets the default `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams`. This will set a default color scheme that applies when no CustomTabColorSchemeParams specified for current color scheme via `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setColorSchemeParams(int,androidx.browser.customtabs.CustomTabColorSchemeParams)`.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams params` | An instance of `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabColorSchemeParams`. |

### setDefaultShareMenuItemEnabled

Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0) Deprecated in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder [setDefaultShareMenuItemEnabled](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultShareMenuItemEnabled(boolean))(boolean enabled)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setShareState(int)` instead. This will set the share state to `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#SHARE_STATE_ON()` or `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#SHARE_STATE_OFF()` based on `enabled`.

Set whether a default share item is added to the menu.

| Parameters |
|---|---|
| `boolean enabled` | Whether default share item is added. |

### setDownloadButtonEnabled

Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/browser#1.7.0)

```
public @NonNull CustomTabsIntent.Builder setDownloadButtonEnabled(boolean enabled)
```

Enables or disables the download button in the overflow menu. The button is enabled by default.

| Parameters |
|---|---|
| `boolean enabled` | Whether the download button is enabled. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_DISABLE_DOWNLOAD_BUTTON()` |   |

### setEphemeralBrowsingEnabled

Added in [1.9.0](https://developer.android.com/jetpack/androidx/releases/browser#1.9.0)

```
public @NonNull CustomTabsIntent.Builder setEphemeralBrowsingEnabled(boolean enabled)
```

Sets whether to enable ephemeral browsing within the Custom Tab. If ephemeral browsing is enabled, and the browser supports it, the Custom Tab does not share cookies or other data with the browser.

| Parameters |
|---|---|
| `boolean enabled` | Whether ephemeral browsing is enabled. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_ENABLE_EPHEMERAL_BROWSING()` |   |

### setExitAnimations

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setExitAnimations(
    @NonNull Context context,
    @AnimRes int enterResId,
    @AnimRes int exitResId
)
```

Sets the exit animations.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/content/Context.html context` | Application context. |
| `@https://developer.android.com/reference/androidx/annotation/AnimRes int enterResId` | Resource ID of the "enter" animation for the application. |
| `@https://developer.android.com/reference/androidx/annotation/AnimRes int exitResId` | Resource ID of the "exit" animation for the browser. |

### setInitialActivityHeightPx

Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/browser#1.5.0)

```
public @NonNull CustomTabsIntent.Builder setInitialActivityHeightPx(@Dimension(unit = 1) int initialHeightPx)
```

Sets the Custom Tab Activity's initial height in pixels with default resize behavior. The Custom Tab will behave as a bottom sheet if the screen's width is smaller than the breakpoint value set by `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActivitySideSheetBreakpointDp(int)`.

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setInitialActivityHeightPx(int,int)` |   |

### setInitialActivityHeightPx

Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/browser#1.5.0)

```
public @NonNull CustomTabsIntent.Builder setInitialActivityHeightPx(
    @Dimension(unit = 1) int initialHeightPx,
    int activityHeightResizeBehavior
)
```

Sets the Custom Tab Activity's initial height in pixels and the desired resize behavior. The Custom Tab will behave as a bottom sheet if the screen's width is smaller than the breakpoint value set by `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActivitySideSheetBreakpointDp(int)`.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/Dimension(unit = 1) int initialHeightPx` | The Custom Tab Activity's initial height in pixels. |
| `int activityHeightResizeBehavior` | Desired height behavior. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_INITIAL_ACTIVITY_HEIGHT_PX()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_ACTIVITY_HEIGHT_RESIZE_BEHAVIOR()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_HEIGHT_DEFAULT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_HEIGHT_ADJUSTABLE()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#ACTIVITY_HEIGHT_FIXED()` |   |

### setInitialActivityWidthPx

Added in [1.8.0](https://developer.android.com/jetpack/androidx/releases/browser#1.8.0)

```
public @NonNull CustomTabsIntent.Builder setInitialActivityWidthPx(@Dimension(unit = 1) int initialWidthPx)
```

Sets the Custom Tab Activity's initial width in pixels. The Custom Tab will behave as a side sheet if the screen's width is bigger than the breakpoint value set by `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setActivitySideSheetBreakpointDp(int)` and the screen is big enough, see doc for `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_INITIAL_ACTIVITY_WIDTH_PX()`.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/Dimension(unit = 1) int initialWidthPx` | The Custom Tab Activity's initial width in pixels. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_INITIAL_ACTIVITY_WIDTH_PX()` |   |

### setInitialNavigationAllowedToLeaveBrowser

Added in [1.9.0](https://developer.android.com/jetpack/androidx/releases/browser#1.9.0)

```
@ExperimentalInitialNavigationCanLeaveBrowser
public @NonNull CustomTabsIntent.Builder setInitialNavigationAllowedToLeaveBrowser(boolean enabled)
```

Allows the Custom Tab to forward the initial URL sent to the Custom Tab to the default handling app for that URL instead of loading it (including following any redirects) in the Custom Tab.

Note: This is not the default behavior. The default for this is to be set to false.

| Parameters |
|---|---|
| `boolean enabled` | Whether the initial URL sent to the custom tab should be sent to the default handling app for that URL. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_INITIAL_NAVIGATION_CAN_LEAVE_BROWSER()` |   |

### setInstantAppsEnabled

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setInstantAppsEnabled(boolean enabled)
```

Sets whether Instant Apps is enabled for this Custom Tab.

| Parameters |
|---|---|
| `boolean enabled` | Whether Instant Apps should be enabled. |

### setNavigationBarColor

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0) Deprecated in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder [setNavigationBarColor](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setNavigationBarColor(int))(@ColorInt int color)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)` instead.

Sets the navigation bar color. Has no effect on API versions below L. To ensure good contrast between navigation bar icons and the background, Custom Tab implementations may use `https://developer.android.com/reference/android/view/View.html#SYSTEM_UI_FLAG_LIGHT_NAVIGATION_BAR` on Android O and above, and darken the provided color on Android L-N. Can be overridden for particular color schemes, see `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setColorSchemeParams(int,androidx.browser.customtabs.CustomTabColorSchemeParams)`.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/ColorInt int color` | The color for the navigation bar. |

### setNavigationBarDividerColor

Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0) Deprecated in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder [setNavigationBarDividerColor](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setNavigationBarDividerColor(int))(@ColorInt int color)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)` instead.

Sets the navigation bar divider color. Has no effect on API versions below P. Can be overridden for particular color schemes, see `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setColorSchemeParams(int,androidx.browser.customtabs.CustomTabColorSchemeParams)`.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/ColorInt int color` | The color for the navigation bar divider. |

### setNetwork

Added in [1.9.0](https://developer.android.com/jetpack/androidx/releases/browser#1.9.0)

```
public @NonNull CustomTabsIntent.Builder setNetwork(@NonNull Network network)
```

Sets the target network `https://developer.android.com/reference/android/net/Network.html` to bind when launching a custom tab. This API allows the caller to specify the target network to bind when launching a URL via Custom Tabs, e.g. may want to open a custom tab over a Wi-Fi network, while the default network is a cellular connection. All URLRequests created in the future via this tab will be bound to `https://developer.android.com/reference/android/net/Network.html`. If the browser does not support this feature it will be ignored and a Custom Tab will be opened using the default network. Check the support by calling `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsClient#isSetNetworkSupported(android.content.Context,java.lang.String)`.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/net/Network.html network` | `https://developer.android.com/reference/android/net/Network.html` the target network to be bound. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_NETWORK()` |   |

### setOpenInBrowserButtonState

Added in [1.9.0](https://developer.android.com/jetpack/androidx/releases/browser#1.9.0)

```
public @NonNull CustomTabsIntent.Builder setOpenInBrowserButtonState(int openInBrowserState)
```

Sets the state for the Open in Browser button in the toolbar for this Custom Tab.

| Parameters |
|---|---|
| `int openInBrowserState` | Desired Open in Browser state. |

| Throws |
|---|---|
| `https://developer.android.com/reference/java/lang/IllegalArgumentException.html` | when an invalid option is provided. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_OPEN_IN_BROWSER_STATE()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#OPEN_IN_BROWSER_STATE_DEFAULT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#OPEN_IN_BROWSER_STATE_ON()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#OPEN_IN_BROWSER_STATE_OFF()` |   |

### setPendingSession

Added in [1.9.0](https://developer.android.com/jetpack/androidx/releases/browser#1.9.0)

```
public @NonNull CustomTabsIntent.Builder setPendingSession(@NonNull CustomTabsSession.PendingSession session)
```

Associates the `https://developer.android.com/reference/android/content/Intent.html` with the given `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession.PendingSession`. Overrides the effect of `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setSession(androidx.browser.customtabs.CustomTabsSession)`.

### setSecondaryToolbarColor

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0) Deprecated in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder [setSecondaryToolbarColor](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setSecondaryToolbarColor(int))(@ColorInt int color)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)` instead.

Sets the color of the secondary toolbar. Can be overridden for particular color schemes, see `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setColorSchemeParams(int,androidx.browser.customtabs.CustomTabColorSchemeParams)`.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/ColorInt int color` | The color for the secondary toolbar. |

### setSecondaryToolbarSwipeUpGesture

Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/browser#1.7.0)

```
public @NonNull CustomTabsIntent.Builder setSecondaryToolbarSwipeUpGesture(@Nullable PendingIntent pendingIntent)
```

Sets the `https://developer.android.com/reference/android/app/PendingIntent.html` to be sent when the user swipes up from the secondary (bottom) toolbar.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent` | The `https://developer.android.com/reference/android/app/PendingIntent.html` that will be sent when the user swipes up from the secondary toolbar. |

### setSecondaryToolbarViews

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setSecondaryToolbarViews(
    @NonNull RemoteViews remoteViews,
    @Nullable int[] clickableIDs,
    @Nullable PendingIntent pendingIntent
)
```

Sets the remote views displayed in the secondary toolbar in a custom tab.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/widget/RemoteViews.html remoteViews` | The `https://developer.android.com/reference/android/widget/RemoteViews.html` that will be shown on the secondary toolbar. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html int[] clickableIDs` | The IDs of clickable views. The onClick event of these views will be handled by custom tabs. |
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/Nullable.html https://developer.android.com/reference/android/app/PendingIntent.html pendingIntent` | The `https://developer.android.com/reference/android/app/PendingIntent.html` that will be sent when the user clicks on one of the `https://developer.android.com/reference/android/view/View.html`s in clickableIDs. When the `https://developer.android.com/reference/android/app/PendingIntent.html` is sent, it will have the current URL as its intent data. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_REMOTEVIEWS()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_REMOTEVIEWS_VIEW_IDS()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_REMOTEVIEWS_PENDINGINTENT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_REMOTEVIEWS_CLICKED_ID()` |   |

### setSendToExternalDefaultHandlerEnabled

Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/browser#1.7.0)

```
public @NonNull CustomTabsIntent.Builder setSendToExternalDefaultHandlerEnabled(boolean enabled)
```

Enables sending any redirects off of the initial URL sent to the Custom Tab to default handling apps. Unless #EXTRA_INITIAL_NAVIGATION_CAN_LEAVE_BROWSER is also set, the initial URL will still always load in the Custom Tab.

| Parameters |
|---|---|
| `boolean enabled` | Whether to send urls to external handler. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_SEND_TO_EXTERNAL_DEFAULT_HANDLER()` |   |

### setSession

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setSession(@NonNull CustomTabsSession session)
```

Associates the `https://developer.android.com/reference/android/content/Intent.html` with the given `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsSession`. Guarantees that the `https://developer.android.com/reference/android/content/Intent.html` will be sent to the same component as the one the session is associated with.

### setShareIdentityEnabled

Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/browser#1.7.0)

```
public @NonNull CustomTabsIntent.Builder setShareIdentityEnabled(boolean enabled)
```

Allow Custom Tabs to obtain the caller's identity i.e. package name.

| Parameters |
|---|---|
| `boolean enabled` | Whether the identity sharing is enabled. |

### setShareState

Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder setShareState(int shareState)
```

Sets the share state that should be applied to the custom tab.

| Parameters |
|---|---|
| `int shareState` | Desired share state. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#SHARE_STATE_DEFAULT()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#SHARE_STATE_ON()` |   |
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#SHARE_STATE_OFF()` |   |

### setShowTitle

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setShowTitle(boolean showTitle)
```

Sets whether the title should be shown in the custom tab.

| Parameters |
|---|---|
| `boolean showTitle` | Whether the title should be shown. |

### setStartAnimations

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0)

```
public @NonNull CustomTabsIntent.Builder setStartAnimations(
    @NonNull Context context,
    @AnimRes int enterResId,
    @AnimRes int exitResId
)
```

Sets the start animations.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/android/content/Context.html context` | Application context. |
| `@https://developer.android.com/reference/androidx/annotation/AnimRes int enterResId` | Resource ID of the "enter" animation for the browser. |
| `@https://developer.android.com/reference/androidx/annotation/AnimRes int exitResId` | Resource ID of the "exit" animation for the application. |

### setToolbarColor

Added in [1.2.0](https://developer.android.com/jetpack/androidx/releases/browser#1.2.0) Deprecated in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder [setToolbarColor](https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setToolbarColor(int))(@ColorInt int color)
```

> [!CAUTION]
> **This method is deprecated.**   
>
> Use `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setDefaultColorSchemeParams(androidx.browser.customtabs.CustomTabColorSchemeParams)` instead.

Sets the toolbar color. On Android L and above, this color is also applied to the status bar. To ensure good contrast between status bar icons and the background, Custom Tab implementations may use `https://developer.android.com/reference/android/view/View.html#SYSTEM_UI_FLAG_LIGHT_STATUS_BAR` on Android M and above, and use a darkened color for the status bar on Android L. Can be overridden for particular color schemes, see `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent.Builder#setColorSchemeParams(int,androidx.browser.customtabs.CustomTabColorSchemeParams)`.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/ColorInt int color` | `https://developer.android.com/reference/android/graphics/Color.html` |

### setToolbarCornerRadiusDp

Added in [1.5.0](https://developer.android.com/jetpack/androidx/releases/browser#1.5.0)

```
public @NonNull CustomTabsIntent.Builder setToolbarCornerRadiusDp(@Dimension(unit = 0) int cornerRadiusDp)
```

Sets the toolbar's top corner radii in dp.

| Parameters |
|---|---|
| `@https://developer.android.com/reference/androidx/annotation/Dimension(unit = 0) int cornerRadiusDp` | The toolbar's top corner radii in dp. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_TOOLBAR_CORNER_RADIUS_DP()` |   |

### setTranslateLocale

Added in [1.7.0](https://developer.android.com/jetpack/androidx/releases/browser#1.7.0)

```
public @NonNull CustomTabsIntent.Builder setTranslateLocale(@NonNull Locale locale)
```

Specifies the target locale the Translate UI should be triggered with.

| Parameters |
|---|---|
| `@https://jspecify.dev/docs/api/org/jspecify/annotations/NonNull.html https://developer.android.com/reference/java/util/Locale.html locale` | `https://developer.android.com/reference/java/util/Locale.html` object that represents the target locale. |

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/browser/customtabs/CustomTabsIntent#EXTRA_TRANSLATE_LANGUAGE_TAG()` |   |

### setUrlBarHidingEnabled

Added in [1.3.0](https://developer.android.com/jetpack/androidx/releases/browser#1.3.0)

```
public @NonNull CustomTabsIntent.Builder setUrlBarHidingEnabled(boolean enabled)
```

Set whether the url bar should hide as the user scrolls down on the page.

| Parameters |
|---|---|
| `boolean enabled` | Whether url bar hiding is enabled. |