The shape-outside property defines the float area for floated elements. When applied, it causes inline content to wrap around the defined shape rather than the element's bounding box. Percentages in shape functions refer to the reference box dimensions..float {
shape-outside: circle(50%);
}.float {
float: right;
shape-outside: polygon(0 0, 100% 0, 100% 100%);
shape-margin: 1rem;
}min:0max:9999step:1units:% | px | em | remnoneThe default value. The float area is the element's margin box (no shape modification).margin-boxReference box: margin edge (default when shape-box is omitted).border-boxReference box: border edge.padding-boxReference box: padding edge.content-boxReference box: content edge.inset()Rectangle with inward offsets (top, right, bottom, left), with optional round for corners.circle()Circle with a radius and optional center position.ellipse()Ellipse with two radii (x, y) and optional center position.polygon()Polygon from points — a list of coordinate pairs.path()SVG path syntax (d= attribute).shape()Responsive shape with path-like commands but using CSS units.url()Image by URL — its alpha channel defines the shape.linear-gradient()Linear gradient as shape source image.radial-gradient()Radial gradient as shape source image.image-set()Selects an image by resolution/format.CSS Shapes Module Level 1Editor's Draft<basic-shape> <shape-box> <image>W3CMDNIn the beginning God created the heavens and the earth.
Now the earth was formless and empty, darkness was over the surface of the deep, and the Spirit of God was hovering over the waters.
And God said, “Let there be light,” and there was light.
God saw that the light was good, and he separated the light from the darkness.
God called the light “day,” and the darkness he called “night.” And there was evening, and there was morning—the first day.
And God said, “Let there be a vault between the waters to separate water from water.”
So God made the vault and separated the water under the vault from the water above it. And it was so.
God called the vault “sky.” And there was evening, and there was morning—the second day.
Show all codeEdit CSS onlineThe plugin that remembers hundreds of CSS items for youEvery CSS property — in a live demonstrationThe bilingual CSS referencedefinitionexamplessyntaxmodulespecificationvalue typessourcesvisual demonstrationpreviousnext