Introduction
In enterprise software, user interface (UI) design is not just about good looks — it’s about adaptability, consistency, and flexibility. Large organizations often have multiple brands, regional clients, or departments that require their own color schemes, logos, and typography, all under a single unified application.
To achieve this, developers need a multi-theme architecture that allows brand customization without rebuilding or redeploying the app.
In this guide, we’ll go step-by-step through building a multi-theme and brand customization system using Angular (frontend) and ASP.NET Core (backend) — ideal for enterprise-scale products.
Why Multi-Theming is Essential in Enterprise UIs
Enterprises typically manage:
Multiple client-specific branding requirements
White-labeled portals (same app, different visuals)
Regional or accessibility-based color preferences
Dark/Light mode for modern UX
Manually maintaining separate codebases for each theme is inefficient. Instead, a centralized theming system ensures:
Quick rollout of new themes or clients
Consistent UX across modules
Dynamic runtime theme switching
Easier maintainability and testing
The Importance of Theming and Branding
A scalable enterprise app needs both functional theming (colors, layout, icons) and brand theming (logos, fonts, identity).
| Type | Purpose | Example |
|---|---|---|
| Functional Theme | User preference or accessibility | Dark/Light Mode |
| Brand Theme | Client-specific identity | “Brand A” uses blue, “Brand B” uses red |
A good system separates core layout logic from theme presentation, ensuring that adding a new brand is just configuration — not new development.
Common Enterprise Requirements
Dynamic Light/Dark Mode Switching
Users can toggle between modes without page reload.Multiple Brand Palettes
Each client gets unique color, logo, and font.Runtime Theme Loading
Theme data fetched from backend during login or context change.Brand Assets from API
Logos, favicons, and accent colors loaded dynamically from an ASP.NET Core API.Accessibility Compliance
All color contrasts meet WCAG 2.1 AA standards.
Architecture Overview
The high-level architecture of a multi-theme enterprise app looks like this:
+---------------------------------------------------+
| User Interface (Angular) |
|---------------------------------------------------|
| - Theme Service |
| - CSS Variables / SCSS Mixins |
| - Angular Material Palette |
+---------------------------------------------------+
| API Layer (ASP.NET Core) |
|---------------------------------------------------|
| - Brand Configuration Controller |
| - Fetch theme colors, fonts, logo URLs |
| - Serve JSON responses |
+---------------------------------------------------+
| Database Layer |
|---------------------------------------------------|
| - Brand table: BrandId, PrimaryColor, Font, Logo |
+---------------------------------------------------+Technical Flowchart: Theme Customization Workflow
┌─────────────────────┐
│ User Logs In │
└────────┬────────────┘
│
▼
┌──────────────────────────┐
│ ASP.NET Core API loads │
│ brand/theme info from DB│
└────────┬─────────────────┘
│ (returns JSON)
▼
┌──────────────────────────┐
│ Angular loads Theme JSON │
│ via ThemeService │
└────────┬─────────────────┘
│
▼
┌──────────────────────────┐
│ CSS variables + logo set │
│ dynamically via renderer │
└──────────────────────────┘
Implementation Approaches in Angular
There are multiple ways to implement dynamic theming in Angular:
Using CSS Variables (Recommended for modern Angular)
Using SCSS Mixins with Angular Material Palettes
Dynamic Class Injection (for older browsers)
Let’s explore a practical implementation.
Step 1: Define CSS Variables
In styles.scss:
:root {
--primary-color: #0078d7;
--secondary-color: #2b2b2b;
--text-color: #222;
}
[data-theme="dark"] {
--primary-color: #1e88e5;
--secondary-color: #121212;
--text-color: #fff;
}
Use these variables in components:

Join the conversation! Your thoughts help the community grow.