StyleKit

Liquid Glass

液态玻璃

Rate this style

Clear glass floats above the content, bending detail near a fine white rim. Floating navigation, search, and controls compress on press, stretch with the gesture, and spring back on release.

liquid glassApple Liquid Glasstransparent materialglassmorphismoptical refractionfloating dockthin specular rimspring motion

Best For

liquid glass / Apple Liquid Glass / transparent material

Primary Move

Place floating navigation and key controls in the glass layer; keep reading and long lists on solid surfaces.

Watch Out

Avoid neon headlines, painted rainbow borders, glowing outlines, and exaggerated RGB separation; very subtle optical dispersion is allowed.

design.md

Liquid Glass as a design document

One document describes the colour roles, type rules, spacing and component construction behind this style. Copy or download it into Claude Code or Codex.

Document view

Liquid Glass — Style Reference

Glass lets the scene through, bends it softly at the rim, and springs back to touch.

Theme: mixed

Liquid Glass combines a clear scene, a thin neutral surface, a fine directional rim highlight, and measured refraction. Reserve it for floating navigation, search, playback controls, and temporary menus; keep body copy and information cards steady and easy to read. Compatible environments must enable SVG backdrop displacement by default, with visible curvature at the rim and an undistorted center. White transparency plus blur is only a fallback, not the complete material. A curved optical profile and very subtle dispersion may be used. Keep labels legible on both light and dark backdrops. A press compresses briefly, a drag stretches slightly, and release settles over roughly 420ms.

Reference

Reference URL: <https://developer.apple.com/design/human-interface-guidelines/materials>

Colors

NameValueTokenRole
Paper#F3F2ED--color-paperA quiet, low-contrast canvas that keeps floating glass and text clear.
Graphite Ink#202929--color-inkThe primary text color for headings, body copy, and controls on light surfaces.
Deep Sea Scene#25414A--color-glass-scenePhotographic, tonal, or lined content that glass can reveal and refract; dark floating layers use white text here.
Salt Mist#E4EFEB--color-glass-mistA muted blue-green used as the quiet base of a tinted material, never as a glow.
Glancing Light#FFFFFF--color-glass-glintA one-pixel highlight along the lit edge that reveals the surface curvature.
Sage Focus#557B79--color-focusFocus rings and a few state cues on light controls, with enough contrast to stay visible.

Typography

System UI — Use the platform system face for a natural feel. Establish hierarchy with size, space, and medium weights, without strokes or glow.
  • Substitute: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif
  • Weights: 400, 500, 600
  • Sizes: 12, 14, 16, 20, 28, 40, 56
  • Line height: 1.05 (display), 1.18 (headings), 1.55 (body)
  • Letter spacing: -0.045em on display, 0.025em on uppercase labels
Type Scale
RoleFamilyWeightSizeLine HeightLetter SpacingToken
display—50056px1.05-0.045em--text-display
heading-lg—50040px1.12-0.035em--text-heading-lg
heading—60028px1.2—--text-heading
subheading—50020px1.35—--text-subheading
body-lg—40016px1.55—--text-body-lg
body—40014px1.5—--text-body
label—50012px1.350.025em--text-label

Spacing & Layout

Base unit: 8px Density: comfortable

Spacing Scale
NameValueToken
44px--spacing-4
88px--spacing-8
1212px--spacing-12
1616px--spacing-16
2424px--spacing-24
3232px--spacing-32
4848px--spacing-48
6464px--spacing-64
8888px--spacing-88
Border Radius
ElementValue
buttons and navigation999px
search and segmented controls999px
cards24px
menus and sheets28px
  • Page max-width: 1120px
  • Section gap: 88px
  • Card padding: 24px
  • Element gap: 16px

Components

Floating Glass Bar

Role: Primary navigation and scene switching

A 56–64px capsule dock with at least a 44px hit area. Place it over a colorful photograph or content: the clear state uses low tint, real backdrop displacement enabled by default, and a one-pixel directional glint. Keep the center flat and refraction within an approximately 8–24px curved rim; subtle dispersion is allowed. Use white icons and labels on dark scenes; add a neutral tint on bright scenes so labels stay visible. The selected pill slides with drag, compresses to 0.96 on press, widens slightly while dragging, then springs home in about 420ms. Give keyboard focus a crisp two-pixel ring.

  • Sizes: 56–64px overall height; at least 44px per hit area; capsule radius
  • States: Idle; 110ms press compression; drag with slight horizontal stretch; 420ms spring settle; keyboard focus; disabled
Clear Glass Button

Role: A light action over a photo or media

A capsule at least 44px tall, with a low-tint surface, real edge refraction, and a fine top glint; use soft blur only as a fallback. Prefer white labels over dark scenes; switch to dark labels and a neutral tint over bright imagery. Compress lightly to 0.96 over about 110ms on press and return with a roughly 420ms spring. Respect reduced-motion preferences. Do not use the clear state when there is no visible content beneath it.

  • Sizes: 44px minimum hit target; capsule radius; 12–16px horizontal inset
  • States: Rest; hover edge glint; compress on press; visible focus; disabled at readable opacity
Tinted Glass Menu

Role: Short menus and temporary choices

A 22–28px corner radius and a more opaque warm-white or sage-tinted layer carry short labels, choices, and icons. Keep backdrop blur moderate, shadows soft, and the top glint fine. Menu text stays ink-colored. Put long explanations and complex settings on a stable solid panel.

  • Sizes: 22–28px radius; 8–16px item spacing; menu rows at least 44px high
  • States: Resting; focused or selected row; open; dismiss; keyboard navigation
Glass Search Field

Role: Search over photography and color

A rounded capsule at least 44px tall, with a tinted refracting outer surface, a flat center, and blur only as an unsupported-browser fallback. Search text and results use dark ink; keep placeholder contrast readable. The rim highlight remains still. Show keyboard focus with a separate high-contrast sage ring, not a glow.

  • Sizes: 44–52px height; capsule radius; 12–16px horizontal inset
  • States: Empty; editing; focus-visible; clear action; results; no results; disabled
Solid Reading Card

Role: Explanatory copy, data, and long-form content

Use a stable warm-white solid surface, a 22–24px radius, and 24px padding. At most, add a low-contrast neutral divider and soft outer shadow. Keep refraction off so scrolling backdrops cannot compete with reading.

  • Sizes: 22–24px radius; 24px padding; generous text measure
  • States: Stable reading surface; optional subtle hover when interactive

Do's and Don'ts

Do
  • Use clear glass for navigation and controls only when there is visible content beneath
  • Choose white or ink labels to keep contrast clear on each backdrop
  • Use a one-pixel directional glint and slight displacement to reveal curvature
  • Tint short transient content such as menus to preserve contrast
  • Keep body copy, tables, and dense information on steady solid surfaces
  • Compress lightly on an approximately 110ms press, stretch a little while dragging, and spring back over about 420ms
  • Respect reduced-motion and reduced-transparency accessibility preferences
  • Keep a readable frosted surface and fine glint when live refraction is unavailable
Don't
  • Do not use rainbow rims, neon headline strokes, or colored glow as refraction
  • Do not spread clear glass across cards, body copy, and the whole page
  • Do not place clear glass on a flat ground with nothing to reveal
  • Do not let glints or refraction reduce text, icon, or focus contrast
  • Do not randomly morph corner radii at rest; liquid feedback should follow interaction
  • Do not assume live filter support is identical across browsers

Surfaces

LevelNameValuePurpose
0Paper canvas#F3F2EDStable reading and content surface
1Clear glassrgba(255, 255, 255, 0.12)Floating controls on a rich, darker scene
2Tinted glassrgba(239, 245, 242, 0.86)Menus and short labels over a bright or detailed scene
3Solid content#FCFCFALong-form copy, data, and controls requiring steady contrast

Elevation

  • Floating control: 0 8px 24px rgba(19, 37, 41, 0.12), inset 0 1px 0 rgba(255,255,255,0.72)
  • Transient panel: 0 16px 40px rgba(19, 37, 41, 0.18), inset 0 1px 0 rgba(255,255,255,0.78)

Imagery

Give clear glass real detail to reveal: photography, quiet contour lines, tonal shifts, or a geometric grid. Place the texture beneath floating controls so straight lines and fine detail shift slightly at the rim while the center stays calm. Avoid rainbow gradients, neon type, and blank single-color grounds that rely on blur alone.

Layout

Organize the page on warm paper, with a detailed photograph, contours, or a grid as the preview stage, checking both bright and dark backdrops. Keep a clear hierarchy from stable content to floating controls: navigation and short menus may hover, while the information itself stays on a solid legible surface. Center the scene and dock on desktop; on narrow screens retain the same touch-sized capsule and leave room for system safe areas.

Agent Prompt Guide

Implementation Contract
  • Use the requested page, user task and real content as the brief. Implement only the requested scope; identify missing business information instead of inventing data or capabilities.
  • Inspect the current project, stack and components first. Reuse its structure, routes, dependencies and components; do not rebuild unrelated pages or features.
  • Use the project's breakpoints to adapt columns and spacing for narrow and desktop screens. Preserve hierarchy and prevent accidental horizontal overflow.
  • For interactions in scope, support keyboard focus and reduced motion, with applicable disabled, loading, empty and error states.
  • Run the project's existing checks after implementation. Report only tests and visual checks actually run, and list unverified behavior.

QUICK COLOR REFERENCE:

  • text: #202929
  • background: #F3F2ED
  • scene: #25414A
  • glassTint: rgba(255, 255, 255, 0.12)
  • glint: rgba(255, 255, 255, 0.72)
  • focus: #557B79

EXAMPLE COMPONENT PROMPTS:

  1. Design a clear liquid-glass dock over photography with fine lines and tonal detail. Use low neutral tint, a one-pixel directional glint, and SVG backdrop displacement enabled by default. Build a narrow rim from surface normals and a refraction profile with a flat center. Allow very subtle dispersion without painted rainbow borders. Give each option a 44px minimum hit area and keep labels legible against light or dark scenes. Lightly compress on press, stretch slightly sideways during drag, then spring back in about 420ms. Add keyboard focus and honor reduced motion. Keep body copy and information cards on warm-white solid surfaces; use a more opaque sage-tinted layer for menus. Enable live backdrop refraction only in Chromium and retain the same surface with a frosted fallback elsewhere. Avoid rainbow rims, neon text, and continuous idle morphing.

Similar Brands

  • Apple Style (apple-style) — Shares system type, restrained hierarchy, and whitespace; Liquid Glass adds edge refraction and touch response.
  • macOS Vibrancy (macos-vibrancy) — Also lets content show through controls; Liquid Glass adds clearer optical curvature at the edge and elastic touch feedback.

Required Optical Implementation and Source References

On compatible engines, navigation, buttons, search, and overlays must use a real backdrop-refraction renderer with visible edge bending; backdrop-blur alone is insufficient. StyleKit uses components/liquid-glass/liquid-glass.tsx with lib/liquid-glass/optics.ts: a Snell curved-rim profile, analytic rounded-rectangle normals, a neutral center, size-bounded displacement, subtle optional dispersion, and a pointer-directed rim highlight. CSS recipes describe the fallback and must be paired with that renderer. Verify with the same-position Glass/Frost comparison and a grid; cancellation restores the drag start and keyboard controls offer equivalent actions. Pinned references: rdev https://github.com/rdev/liquid-glass-react/tree/ac48eab18d1f7f444ae30002d240cae29c863a21; glassy https://github.com/9und30/glassy-liquid/tree/2361eb1f03979703db988180028ccc6d5fc23fe5; shuding https://github.com/shuding/liquid-glass/tree/a2d2e847f793430e3409a52927af815a23f4d372. All are MIT; retain full notices when copying or adapting. StyleKit includes the glassy MIT notice for its adapted optical profile. Generic blur support does not establish SVG backdrop support in Safari/Firefox: use an explicit scene renderer when refraction there is required, otherwise label the fallback.

Quick Start


:root {
  /* Colors */
  --color-paper: #F3F2ED;
  --color-ink: #202929;
  --color-glass-scene: #25414A;
  --color-glass-mist: #E4EFEB;
  --color-glass-glint: #FFFFFF;
  --color-focus: #557B79;

  /* Typography — Font Families */
  --font-sans: 'System UI', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Typography — Scale */
  --text-display: 56px;
  --leading-display: 1.05;
  --tracking-display: -0.045em;
  --text-heading-lg: 40px;
  --leading-heading-lg: 1.12;
  --tracking-heading-lg: -0.035em;
  --text-heading: 28px;
  --leading-heading: 1.2;
  --text-subheading: 20px;
  --leading-subheading: 1.35;
  --text-body-lg: 16px;
  --leading-body-lg: 1.55;
  --text-body: 14px;
  --leading-body: 1.5;
  --text-label: 12px;
  --leading-label: 1.35;
  --tracking-label: 0.025em;

  /* Typography — Weights */
  --font-weight-regular: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;

  /* Spacing */
  --spacing-unit: 8px;
  --spacing-4: 4px;
  --spacing-8: 8px;
  --spacing-12: 12px;
  --spacing-16: 16px;
  --spacing-24: 24px;
  --spacing-32: 32px;
  --spacing-48: 48px;
  --spacing-64: 64px;
  --spacing-88: 88px;

  /* Layout */
  --page-max-width: 1120px;
  --section-gap: 88px;
  --card-padding: 24px;
  --element-gap: 16px;
  --density: comfortable;

  /* Border Radius */
  --radius-buttons-and-navigation: 999px;
  --radius-search-and-segmented-controls: 999px;
  --radius-cards: 24px;
  --radius-menus-and-sheets: 28px;

  /* Surfaces */
  --surface-paper-canvas: #F3F2ED;
  --surface-clear-glass: rgba(255, 255, 255, 0.12);
  --surface-tinted-glass: rgba(239, 245, 242, 0.86);
  --surface-solid-content: #FCFCFA;
}

Community

Ratings & Feedback

No ratings yet - be the firstSign in to rate

Loading comments…

Component Templates

Component Preview

Glass Button

A tinted capsule over a dark scene with a fine rim and tactile press.

Pointer Interactions

How Liquid Glass moves

Pointer interactions tailored to this style — same cursor, completely different character. Move around the stage to feel it.

Frosted alternative. Live refraction is available in Chrome and Edge.

Move your pointer or tap to place the lens. Focus it to use the arrow keys; Home or Enter centers it. Touch swipes scroll normally.

Clear lens with refracting edgesPointer, arrow keys and HomeTap to place; still when idleExplore all rooms in Cursor Lab

FAQ

Liquid Glass — Frequently Asked Questions

What is the Liquid Glass design style?
Clear glass floats above the content, bending detail near a fine white rim. Floating navigation, search, and controls compress on press, stretch with the gesture, and spring back on release. Its core principle: Glass is the control layer.
What colors does Liquid Glass use?
Liquid Glass uses #f3f2ed as its primary color and #202929 as its secondary color, with accent colors #25414a, #e4efeb, #c7e4e5, #557b79. Every hex value can be copied from the palette on this page.
How do I apply Liquid Glass correctly?
Key practices: Place floating navigation and key controls in the glass layer; keep reading and long lists on solid surfaces. Keep recognizable detail at the center, concentrating neutral refraction and a roughly 1px white glint near the rim. Increase tint over bright, busy, or changing scenes to preserve readable labels and visible focus.
What are common mistakes with Liquid Glass?
Avoid: Avoid neon headlines, painted rainbow borders, glowing outlines, and exaggerated RGB separation; very subtle optical dispersion is allowed. Do not give every card or every dock item its own layer of glass. Do not erase the backdrop with heavy blur or describe CSS blur as live refraction.
How do I prompt AI to generate Liquid Glass UI?
Copy the ready-made AI prompt on this page — it bundles the design tokens and component rules — and paste it into ChatGPT, Claude, Claude Code, or Codex. Effective prompts include the keywords: liquid glass, Apple Liquid Glass, transparent material, glassmorphism.
Global Styles

Global CSS

css
/* Liquid Glass fallback skin. Live rim refraction requires the shared LiquidGlass renderer. Use .liquid-system on the owning region. */
.liquid-system {
  --liquid-paper: #f3f2ed;
  --liquid-ink: #202929;
  --liquid-muted: #4c5d57;
  --liquid-scene: #25414a;
  --liquid-glint: rgb(255 255 255 / 62%);
  --liquid-rim: rgb(255 255 255 / 25%);
  --liquid-clear-fill: rgb(15 25 32 / 21%);
  --liquid-tinted-fill: rgb(17 29 37 / 88%);
  --liquid-opaque: #20343b;
  --liquid-on-glass: #fff;
  --liquid-selection: rgb(255 255 255 / 18%);
  --liquid-placeholder: #d5e0e0;
  --liquid-focus: #c7e4e5;
  --liquid-focus-on-paper: #557b79;
  --liquid-panel-radius: 24px;
  --liquid-press: 110ms;
  --liquid-release: 420ms cubic-bezier(.26, 1.55, .52, 1);
  color: var(--liquid-ink);
  background: var(--liquid-paper);
  font-family: system-ui, sans-serif;
}

.liquid-system [data-liquid-tone="light"] {
  --liquid-clear-fill: rgb(243 242 237 / 68%);
  --liquid-tinted-fill: rgb(243 242 237 / 92%);
  --liquid-opaque: #f3f2ed;
  --liquid-on-glass: #202929;
  --liquid-selection: rgb(32 41 41 / 12%);
  --liquid-placeholder: #4c5d57;
  --liquid-focus: var(--liquid-focus-on-paper);
}

.liquid-scene {
  display: grid;
  justify-items: start;
  align-content: center;
  min-block-size: 18rem;
  gap: 1rem;
  padding: clamp(1.5rem, 5vw, 4rem);
  border-radius: var(--liquid-panel-radius);
  color: #fff;
  background:
    repeating-linear-gradient(163deg, transparent 0 19px, rgb(221 239 234 / 16%) 20px 21px),
    linear-gradient(140deg, #18262e, var(--liquid-scene) 62%, #486d72);
}

.liquid-kicker {
  margin: 0;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .08em;
}

.liquid-glass {
  --liquid-fill: var(--liquid-clear-fill);
  --liquid-blur: blur(4px);
  position: relative;
  box-sizing: border-box;
  border: 1px solid var(--liquid-rim);
  border-radius: var(--liquid-panel-radius);
  color: var(--liquid-on-glass);
  background-color: var(--liquid-opaque);
  box-shadow: inset 0 1px 0 var(--liquid-glint), 0 8px 24px -18px rgb(8 24 38 / 55%);
}

.liquid-glass--tinted {
  --liquid-fill: var(--liquid-tinted-fill);
  --liquid-blur: blur(12px);
}

@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .liquid-glass {
    background-color: var(--liquid-fill);
    -webkit-backdrop-filter: var(--liquid-blur);
    backdrop-filter: var(--liquid-blur);
  }
}

/* Only opt in after verifying SVG backdrop support and attaching a live lens map. */
.liquid-glass[data-liquid-optics="svg"] {
  backdrop-filter: var(--liquid-refraction-filter, var(--liquid-blur));
}

.liquid-content {
  padding: clamp(1rem, 3vw, 2rem);
  border: 1px solid #d9e0db;
  border-radius: var(--liquid-panel-radius);
  background: #fff;
  color: var(--liquid-ink);
}

.liquid-dock {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  max-inline-size: 100%;
  padding: 5px;
  border-radius: 999px;
}

.liquid-button,
.liquid-input {
  box-sizing: border-box;
  min-block-size: 44px;
  border-radius: 999px;
  padding: .625rem 1rem;
  font: inherit;
}

.liquid-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}

.liquid-button[aria-current]:not([aria-current="false"]),
.liquid-button[aria-pressed="true"] {
  background: var(--liquid-selection);
  box-shadow: inset 0 1px 0 var(--liquid-glint);
}

.liquid-pressable {
  transition: transform var(--liquid-release);
}

.liquid-pressable:active:not(:disabled) {
  transform: scale(.97, .92);
  transition-duration: var(--liquid-press);
}

.liquid-button:disabled {
  opacity: .55;
  cursor: not-allowed;
}

.liquid-field {
  display: grid;
  gap: .375rem;
}

.liquid-input {
  inline-size: 100%;
}

.liquid-input::placeholder {
  color: var(--liquid-placeholder);
  opacity: 1;
}

.liquid-content :focus-visible {
  outline: 2px solid var(--liquid-focus-on-paper);
  outline-offset: 3px;
}

.liquid-button:focus-visible,
.liquid-input:focus-visible {
  outline: 2px solid var(--liquid-focus);
  outline-offset: 3px;
}

.liquid-system[data-liquid-transparency="reduce"] .liquid-glass {
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  background-color: var(--liquid-opaque);
}

@media (prefers-reduced-transparency: reduce) {
  .liquid-system .liquid-glass {
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    background-color: var(--liquid-opaque);
  }
}

@media (prefers-reduced-motion: reduce) {
  .liquid-system .liquid-pressable {
    transition: none;
  }
  .liquid-system .liquid-pressable:active {
    transform: none;
  }
}

@media (forced-colors: active) {
  .liquid-system .liquid-glass {
    border: 1px solid ButtonText;
    color: ButtonText;
    background: ButtonFace;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    box-shadow: none;
  }
  .liquid-button[aria-current]:not([aria-current="false"]),
  .liquid-button[aria-pressed="true"] {
    outline: 1px solid Highlight;
    outline-offset: -2px;
  }
  .liquid-button:focus-visible,
  .liquid-input:focus-visible {
    outline-color: Highlight;
  }
}

Related Styles

Related Styles

Explore these styles for ready-made tokens and components.

Liquid Glass and Fluent Design sit closest to each other. The table below gives the real differences in color, use case, and tags, so the choice between them is made on facts.

AttributeLiquid GlassFluent Design
Primary color#f3f2ed#0078d4
Secondary color#202929#106ebe
Best forliquid glass / Apple Liquid Glass / transparent materialFluent Design / Microsoft Fluent / acrylic material
Unique tags——
Design Philosophy

Glass is the control layer. Lay out sharp content first, then float the navigation, search, and controls that people need above it. Glass borrows color from the scene, and a fine glint gives the rim depth. Bend the backdrop near the edge and keep its original texture recognizable in the center.

Design Recipes

Recommended Combinations with Liquid Glass

These curated recipes combine this style with layouts and animations, optimized for specific use cases.