---
schema_version: "1"
id: 17c87676c2a92dd8163be68623478fd125c8201185d48e424b9546927cdd3428
title: Android Theming Overview
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/genai/agentforce-mobile-sdk/references/android/theming-overview-android.md
canonical_url: https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/theming-overview-android.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: 79804e7617ca0fc1caf312ef1597e3845d82c9c9384cd55b091e510a4303e8b8
products:
  - Agentforce Mobile SDK
  - Agentforce and Einstein Generative AI
---
# Android Theming Overview

Theming system and visual customization for the Agentforce Android SDK.

The SDK lets you customize colors, typography, icons, on-screen text, and light/dark behavior for every UI component in the full-UI chat experience. All theming types live in the package `com.salesforce.android.agentforcesdk.components.theme`.

## Quick start

Supply a theme once, through `AgentforceConfiguration.Builder.setTheming(...)`. List only the tokens you want to change; everything else keeps its SDK default.

```kotlin
import androidx.compose.ui.graphics.Color
import com.salesforce.android.agentforcesdk.components.theme.AgentforceColorToken
import com.salesforce.android.agentforcesdk.components.theme.AgentforceThemeMode
import com.salesforce.android.agentforcesdk.components.theme.AgentforceThemeOverrides
import com.salesforce.android.agentforcesdk.components.theme.AgentforceTheming

val theming = AgentforceTheming.Overrides(
    AgentforceThemeOverrides(
        lightColors = mapOf(AgentforceColorToken.Accent1 to Color(0xFF0170CB)),
        darkColors = mapOf(AgentforceColorToken.Accent1 to Color(0xFF008AF7)),
        themeMode = AgentforceThemeMode.SYSTEM,
    )
)

val configuration = AgentforceConfiguration.builder(authCredentialProvider)
    .setApplication(application)
    .setSalesforceDomain("https://your-instance.salesforce.com")
    .setTheming(theming)
    .build()
```

## What you can customize

| Area                 | Type(s)                                          | Scope                                                                           |
| -------------------- | ------------------------------------------------ | ------------------------------------------------------------------------------- |
| Colors               | `AgentforceColorPalette`, `AgentforceColorToken` | 271 tokens — 47 foundation plus 224 component-level across 50 component groups. |
| Font family          | `AgentforceTypography.copyWithFontFamily(...)`   | Applies your font to all 23 text styles at once.                                |
| Per-style typography | `Typography.mergeWith(...)`                      | Adjust the weight, size, or line height of individual styles.                   |
| Icons                | `AgentforceIconType`, `AgentforceIcon`           | 23 replaceable icons, with optional separate light and dark variants.           |
| Display-name strings | `AgentforceDisplayNameType`                      | 45 user-visible strings such as titles, hints, and button labels.               |
| Theme mode           | `AgentforceThemeMode`                            | `SYSTEM`, `LIGHT`, or `DARK`.                                                   |

Shapes, dimensions, and shadows come from the Salesforce SharedUI design system and can also be overridden through `AgentforceThemeOverrides` or `createCustomAgentforceThemeManager(...)`, using the SharedUI `Shapes`, `Dimensions`, and `Shadows` types.

## How the pieces fit together

1. You describe your theme with `AgentforceThemeOverrides` (a sparse bag of just the tokens you want to change) or with a fully resolved `AgentforceThemeManager`.
2. You pass it to `setTheming(...)` using the sealed `AgentforceTheming` type: `Default`, `Overrides`, or `CustomManager`.
3. The SDK resolves that into an `AgentforceThemeManager` and publishes it through the `LocalAgentforceTheme` Compose `CompositionLocal`.
4. Every component reads its values from that local, so the UI recomposes when the theme or the device's light/dark setting changes.

Prefer `AgentforceTheming.Overrides`. A fully resolved manager carries no "unset" signal, so there is no way to say "leave this one alone."

## Reference pages

| Page                                                                                                      | What it covers                                                                                                     |
| --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ |
| [Theming guide](/docs/ai/agentforce-mobile-sdk/guide/agentforce-mobile-sdk-android-branding-theming.html) | End-to-end walkthrough: supplying a theme, then customizing colors, typography, icons, strings, and theme mode.    |
| [AgentforceThemeManager](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/agentforce-theme-manager-android.md)                                             | The theme contract, the factory functions, and reading theme values in your own components.                        |
| [AgentforceColors](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/agentforce-colors-android.md)                                                          | The palette class, the default light and dark palettes, the `AgentforceColorToken` enum, and `withOverrides(...)`. |
| [Color Token Reference](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/agentforce-color-token-reference-android.md)                                      | Every one of the 271 color tokens, with its fallback and its default light and dark value.                         |
| [AgentforceTypography](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/agentforce-typography-android.md)                                                  | The 23 text styles with their weights, sizes, and line heights, plus `copyWithFontFamily(...)`.                    |
| [Custom Icons](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/agentforce-icon-type-android.md)                                                           | Every replaceable icon, its default drawable, and which color token tints it.                                      |
| [Display Names](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/agentforce-display-name-type-android.md)                                                  | Every customizable string, its default text, and where it appears.                                                 |
| [Theme Mode](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/agentforce-theme-mode-android.md)                                                            | Light, dark, or follow the system, and how each mode resolves.                                                     |
| [Server-Driven Branding](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/server-driven-branding-android.md)                                               | How an org can supply a theme centrally, and how it merges with your in-code theme.                                |

## Renamed and removed types

If you're coming from older documentation:

| Old name                                           | Use instead                                                                                                                                               |
| -------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `AgentforceColors`                                 | Never a type — it was the file name. The types are `AgentforceColorPalette`, `AgentforceLightColors`, `AgentforceDarkColors`, and `AgentforceColorToken`. |
| `AgentforceThemeCreator`                           | `createDefaultAgentforceThemeManager()` or `createCustomAgentforceThemeManager(...)`.                                                                     |
| `DefaultAgentforceTheme`                           | `createDefaultAgentforceThemeManager()`.                                                                                                                  |
| `Typography` (base class)                          | `AgentforceTypography`, with `Typography.mergeWith(...)` for per-style overrides.                                                                         |
| `SalesforceTextFontScale`                          | Internal to the SDK. Font scaling now follows the device's font-scale setting automatically.                                                              |
| `AgentforceSpacing`, `Spacing`, `Spacing (Styles)` | Internal to the SDK. Override spacing through the SharedUI `Dimensions` type instead.                                                                     |
| `setThemeManager(...)` / `setThemeOverrides(...)`  | `setTheming(...)` with `AgentforceTheming`.                                                                                                               |

`AgentforceThemeManager` is an interface with read-only accessors. You can't construct it directly and there are no setter methods — build one with `createCustomAgentforceThemeManager(...)`, which takes every theme property as a defaulted parameter.

## See also

- **UI Components**: See [Android UI Components](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/ui-components-android.md) for component theming.
- **Configuration**: See [Configuration Overview](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/configuration-overview-android.md) for setup.
- **Integration**: See [Android Development](https://developer.salesforce.com/docs/ai/agentforce-mobile-sdk/references/agentforce-mobile-sdk/development-android.md) for architecture patterns.
