# "CSS Injection" _Path: en/frontend/web-host/css-injection_ > "Reference for CSS delivery across Web Host page engines and web-component shadow roots." ## Table of Contents - CSS Injection ## Content # CSS Injection This page is the configuration reference for Host-delivered CSS. JSON and TypeScript blocks show individual settings and component contracts, not a complete frontend package. For iframe pages, the Web Host uses a layered injection pipeline to give the child document the same visual theme as the host. Because an iframe does not inherit CSS from its parent document, the host injects style assets into the child's `srcdoc`; `ProxyConfig` controls those iframe layers. Web Fragment pages use a separate delivery path described below. This page documents the injection pipeline, all available flags, and how to customize styles at the global, host-chrome, or per-page level. It is the **canonical reference for the `proxy.injections` CSS flags and their runtime defaults** — authoring docs that show recommended explicit values link back here. For the developer-facing theming guide (CSS variable tokens, Tailwind mapping, web component patterns), see [Theming](../micro-frontends/theming.md). ## CSS Delivery Matrix The facade exposes theming through three scopes — **global** (`custom_css`, `css_variables`, `icon_sets`), **host** (`host_custom_css`, `host_css_variables`, `host_icon_sets`), and **children** (`children_custom_css`, `children_css_variables`). The Web Host composes them per surface. Two rules govern everything below: - **CSS custom properties (`*_css_variables`) inherit to a WC host.** WippyElement bridges names from the effective global and children/page maps through its forced-theme inner root so local theme defaults cannot reset them. This is independent of `customCss`; host-only names rely on ordinary inheritance and can be shadowed if local theme CSS redeclares them on the inner root. - **CSS selector rules (`*_custom_css`) do not cross an iframe or shadow boundary by themselves.** The runtime injects them into the selected `view.page` realm and — **as of Web Host 1.0.43** — into each `view.component` shadow root (opt-out via the component's `customCss` flag). Before 1.0.43, only variables reached a component shadow root. | Facade knob | Delivers | Host shell doc | `view.page` child realm | `view.component` shadow root | |---|---|---|---|---| | `custom_css` (global) | selector rules | ✓ injected | ✓ injected¹ | ✓ injected (1.0.43+, opt-out)¹ | | `css_variables` (global) | custom properties | ✓ effective mode blocks | ✓ effective mode blocks | ✓ inherited + bridged | | `host_custom_css` (host) | selector rules | ✓ injected | ✗ | ✗ | | `host_css_variables` (host) | custom properties | ✓ `:root` | ✗ | host-mounted WCs only² | | `children_custom_css` (children) | selector rules | ✗ | ✓ injected¹ | ✓ injected (1.0.43+, opt-out)¹ | | `children_css_variables` (children) | custom properties | ✗ | ✓ `:root` | page WCs only² | ¹ The Web Host **composes** what a child receives: a `view.page` under either engine and a `view.component` get **global + children** custom CSS merged into one sheet (`children_custom_css` appended after `custom_css`). The iframe and component `customCss` flags are gates, not literal single-scope injects; the Web Fragment adapter applies its composed page sheet without that iframe flag. ² A web component inherits custom **properties** from the `:root` of wherever it is mounted: a host-chrome WC inherits **global + host** vars from the host document; a WC inside a `view.page` inherits **global + children** vars from that page realm. The inner-root bridge covers global and children/page variable names, not host-only names. Its injected custom **CSS** is always the children scope (global + children). Keep shared styling in `custom_css` / `css_variables` (global) — those reach every surface regardless of mount location. **`fs://` file support:** the six theming knobs above accept an `fs://` value resolved at request time from the `content_fs` filesystem — see [Facade → Reusing facade theming on non-Web-Host pages](../../framework/facade.md#reusing-facade-theming-on-non-web-host-pages). `icon_sets` / `host_icon_sets` and every non-theming JSON parameter are inline-only. Iconify provider sources use the separate `AppConfig.iconify.providers` field; see [Iconify providers](./iconify.md). The `iconifyIcons` flag controls whether the Host loads and registers the `` custom element. It does not select the collection source and is separate from CSS injection. Configure sources through `AppConfig.iconify.providers`, and keep the default online unless the deployment explicitly selects a local source. For more than a few overrides, keep CSS and JSON in separate files behind `content_fs` and reference them with `fs://`. This keeps theme assets reviewable and reusable. Do not substitute `file://`: that is a loader-time inlining mechanism, not the facade's request-time theming contract. ## The iframe injection pipeline Styles are injected in this logical layering. The first four layers are plain `