CSS lighting-color Property
Description
The lighting-color property controls the color of the virtual light source used by lighting-based filter effects. It does not change the base fill or stroke of the element itself; rather, it determines the hue of the highlights, specular glints, and the colored component of diffuse illumination produced by lighting filter primitives (for example those used inside SVG filters). Because lighting effects are applied as part of the filter pipeline, the color you choose for the light alters how the rendered surface appears to be lit — warm lights give reddish highlights, cool lights give bluish highlights — without altering the underlying geometry or textures.
In practice, lighting-color is used when a filter chain includes primitives that perform lighting calculations; it defines the color used when computing the illumination that is added to (or combined with) the source graphic. When combined with surface properties like the surface normals and material parameters inside the lighting primitive, the light color defines both the diffuse tint and the specular color of reflections. Because the property affects only the light source, you can achieve effects such as colored rim lighting or subtle tints on a shape’s highlights while keeping the object's base color unchanged.
Use of lighting-color is typically coordinated with the overall filter applied to an element, so it is often considered alongside the element’s filter configuration and the element’s own color styling (for example the color of text or fills) to produce the intended visual result. It is also a useful parameter to animate or vary when you want dynamic lighting — for instance simulating time-of-day shifts, neon glows, or interactive color changes in response to user input — because changing the light color re-tints highlights and reflections in a natural way without altering the underlying artwork.
Definition
- Initial value
- white
- Applies to
- <feDiffuseLighting> and <feSpecularLighting> elements in <svg>
- Inherited
- no
- Computed value
- as specified
- Animatable
- by computed value
- JavaScript syntax
- object.style.lightingColor
Syntax
element { lighting-color: <color>; }
Values
- <color>You can use any valid CSS color:
- Color Keywords: Any standard CSS color name (e.g.,
blue,darkgreen,transparent). - Hexadecimal: 3, 4, 6, or 8-digit hex codes (e.g.,
#f06). - RGB/RGBA: Functional notation for Red, Green, and Blue channels.
- HSL/HSLA: Functional notation for Hue, Saturation, and Lightness.
- CurrentColor: Uses the value of the
colorproperty from the element.
- Color Keywords: Any standard CSS color name (e.g.,
Example
Browser Support
The following information will show you the current browser support for the CSS lighting-color property. Hover over a browser icon to see the version that first introduced support for this CSS property.
This property is supported by all modern browsers.
Desktop
Tablets & Mobile
Last updated by CSSPortal on: 1st January 2026
