CSS offset-path Property
Description
The offset-path property defines a geometric path that an element can follow for offset positioning, serving as the foundation of CSS motion-path behavior. It tells the browser which curve, line or shape should be used to compute the element’s visual position along that route; that computed position is then applied to the element during painting so the element appears to travel along the path. Think of offset-path as the track or route, while other offset-related properties determine where on that track an element sits and how it is oriented.
In practice the property is used in tandem with the properties that control the element’s progress along and orientation relative to the path: offset-distance controls how far along the path the element is placed, and offset-rotate controls its rotation relative to the path’s tangent. Because the path-based positioning is applied at paint/compositing time, it normally does not change the document flow or the layout of other elements; it is a visual transformation layered on top of the element’s laid-out box. For that reason it often composes similarly to other visual transforms and can interact with, or be combined with, a regular transform.
Common uses for offset-path include creating intricate motion effects, moving UI elements along non-linear tracks, or animating complex entrance and exit behaviors. It integrates naturally with CSS animation and transition systems — you typically animate the property that represents progress along the path (for example animation keyframes animating offset-distance, or a transition on the same) so the element moves smoothly along the specified route. From a performance and accessibility standpoint, it’s best used where the motion is primarily visual: combining path motion with composited transforms and limiting layout-changing animations helps preserve rendering performance and predictable keyboard/assistive technology behavior.
Definition
- Initial value
- none
- Applies to
- transformable elements
- Inherited
- no
- Computed value
- as specified
- Animatable
- by computed value type
- JavaScript syntax
- object.style.offsetPath
Interactive Demo
Syntax
offset-path: none | path() | ray() | url() | <basic-shape>
Values
- noneSpecifies that the element does not follow any offset path. The none value is equivalent to the element not having any offset transform.
- path()Specify a path in SVG syntax.
- ray()Specify a path with the CSS ray() function.
- url()Specify a path by using the URL to an SVG file.
- <basic-shape>Specify a path by defining a basic shape using CSS functions like inset(), circle(), ellipse() or polygon().
Example
Browser Support
The following information will show you the current browser support for the CSS offset-path 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
