Home › Developer Tools › SVG Path Editor

SVG Path Editor

Paste the d attribute of any SVG path to see it drawn with every point and Bézier handle. Drag points, edit commands as numbers, convert between absolute and relative, scale or move the whole path and copy a minified result. Everything runs in your browser.

Last updated:

Commands 0

    Click a letter to switch absolute / relative. New commands are inserted after the selected one.

    Transform

    Move by
    Scale by
    Convert

    Output

    
          
    Advertisement
    Advertisement

    How to use the SVG Path Editor

    1. Paste your path data (the value of d="…") into the box, or pick an example such as Heart or Speech bubble.
    2. Drag the points on the canvas: round dots are end points, square dots are Bézier control points. Scroll to zoom and drag the background to pan.
    3. Fine-tune numbers in the command list. Click a command letter to switch it between absolute (upper case) and relative (lower case).
    4. Transform the path with Translate and Scale, or convert the whole path to absolute or relative commands.
    5. Press Minify to get the shortest equivalent d string, then copy it or download a ready SVG file.

    SVG path commands reference

    Each command is a letter followed by its numbers. Upper case means absolute coordinates, lower case means coordinates relative to the current point. A letter can be followed by several sets of numbers; the command then repeats (after M, extra pairs become L line-to commands).

    CommandParametersWhat it draws
    M / mx yMoves the pen without drawing and starts a new subpath
    L / lx yStraight line to the point
    H / hxHorizontal line (only x changes)
    V / vyVertical line (only y changes)
    C / cx1 y1 x2 y2 x yCubic Bézier curve with two control points
    S / sx2 y2 x ySmooth cubic: the first control point mirrors the previous curve's second one
    Q / qx1 y1 x yQuadratic Bézier curve with one control point
    T / tx ySmooth quadratic: the control point mirrors the previous one
    A / arx ry rotation large-arc sweep x yElliptical arc to the point; the two flags (0 or 1) choose which of the four possible arcs is drawn
    Z / znoneCloses the subpath with a straight line back to its start point

    How the editor handles absolute and relative commands

    When you drag a point or switch a single command between absolute and relative, the editor first converts the whole path to absolute coordinates, applies the change and then writes each command back in its original form. That way the rest of the shape stays exactly where it was, even when later commands are relative. Typing a number in the command list, on the other hand, edits that raw value, so following relative commands move along with it, just as they would in a text editor.

    Dragging an end point also carries the attached Bézier handles with it, so curves keep their shape around the moved point. Arrow keys nudge the selected point by 1 unit (10 with Shift, or by the snap step).

    What the minifier does

    • Rounds every absolute coordinate to the chosen number of decimals, then derives relative values from the rounded positions so rounding errors never add up.
    • Turns horizontal and vertical L commands into the shorter H and V forms.
    • Writes each command in whichever form (absolute or relative) is shorter.
    • Drops repeated command letters, leading zeros (0.5 becomes .5) and every space that a minus sign or a second decimal point makes unnecessary, e.g. l-1.45-1.32 or 0 .5.5.

    For icons drawn on a 24×24 grid, 2 decimals are usually invisible; for large illustrations 1 or even 0 decimals can be enough.

    Frequently asked questions

    What is the d attribute of an SVG path?

    The d attribute holds the path data: a list of commands, each a letter followed by numbers. M moves the pen, L, H and V draw straight lines, C and S draw cubic Bézier curves, Q and T draw quadratic curves, A draws an elliptical arc and Z closes the shape back to its start point.

    What is the difference between upper and lower case path commands?

    Upper case commands use absolute coordinates measured from the origin of the SVG coordinate system. Lower case commands are relative: their numbers are offsets from the current pen position. Both draw the same shape; relative paths are often shorter and easier to move.

    How do I scale an SVG path?

    Enter a scale factor such as 2 or 0.5 and press Scale. The editor multiplies every coordinate and arc radius; scaling with different X and Y factors stretches the shape, and a negative factor mirrors it (the arc sweep flag is flipped automatically). You can also scale around the path center instead of the origin.

    Is the minified path exactly the same shape?

    Minifying rounds coordinates to the number of decimals you choose, so it can move points by at most half of the last decimal place. Relative values are computed from the rounded positions, so errors do not accumulate along the path. Everything else (removing spaces, leading zeros, repeated letters, choosing absolute or relative) is lossless.

    Why does my path show an error?

    The editor reports the first character it cannot read, for example a missing number, an arc flag that is not 0 or 1, or a path that does not begin with M. Fix that spot and the drawing updates immediately; the last valid path stays on screen until then.

    Does this work with paths from icons and design tools?

    Yes. Paths exported by Figma, Illustrator, Inkscape and icon sets are standard SVG path data. Copy the d value from the SVG file, paste it here, edit it and paste it back. Transforms set on parent groups are not part of d and are not applied.

    Is my SVG uploaded anywhere?

    No. Parsing, drawing and editing happen in JavaScript in your browser. Nothing you paste is sent to a server.

    Are all the tools on FreeToolCabin tested for quality and accuracy?

    Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.

    Related tools

    SVG OptimizerMinify SVG files: strip metadata, comments and editor junk, round numbers, compare sizes.SVG Blob GeneratorGenerate random organic SVG blob shapes with gradients and export SVG, PNG or CSS clip-path.SVG Wave GeneratorMake layered SVG waves for section dividers and export SVG, PNG or a CSS background.CSS Clip-Path GeneratorDraw CSS clip-path shapes by dragging points: polygons, circle, ellipse and inset. Copy the CSS.Open Graph PreviewPaste OG tags and preview how links look on Facebook, X and LinkedIn.YouTube Embed Code GeneratorCreate responsive YouTube embed code with start time, autoplay, loop and privacy mode.CSS Box Shadow GeneratorDesign layered CSS box shadows with a live preview, presets and one-click Copy CSS.CSS Border Radius GeneratorRound each corner, draw elliptical 8-value radii or random blob shapes and copy the CSS.CSS Button GeneratorDesign CSS buttons with gradients, borders, shadows and hover and active states, then copy the code.CSS Flexbox GeneratorBuild flexbox layouts visually: set container and item properties, then copy the CSS and HTML.Twitter Card GeneratorCreate X / Twitter Card meta tags with Open Graph fallbacks, character counters and a live preview.CSS Grid GeneratorDraw CSS grid layouts: set tracks and gaps, drag to name areas, then copy the CSS and HTML.PX to REM ConverterConvert px to rem or em and back, with a 1-100px table and a whole-CSS converter.Glassmorphism CSS GeneratorDesign frosted-glass UI cards with blur, transparency and border sliders, then copy the CSS.CSS Text Shadow GeneratorLayer CSS text shadows with a live preview and neon, 3D, outline and retro presets.HTML Editor (Live Preview)Write HTML, CSS and JavaScript and see a live, sandboxed preview as you type.HTML to JSX ConverterConvert HTML to valid React JSX: className, htmlFor, style objects, self-closing tags and events.CSS Animation GeneratorCreate CSS keyframe animations from 23 presets with live preview, timing controls and Copy CSS.CSS Triangle GeneratorMake CSS triangles in 8 directions with the border trick or clip-path. Set size and color, copy CSS.CSS Loader GeneratorPick from 14 pure CSS spinners and loaders, set color, size and speed, then copy the HTML and CSS.Cubic Bezier GeneratorDrag the control points to design a CSS easing curve, compare it with linear and copy cubic-bezier().CSS Filter GeneratorAdjust blur, brightness, contrast, hue, sepia and drop-shadow on an image and copy the CSS filter.CSS Specificity CalculatorCalculate CSS selector specificity (a, b, c), including :is(), :not(), :has() and :where(), and compare.Google Maps Embed GeneratorTurn an address or coordinates into responsive Google Maps iframe embed code, no API key.Neumorphism CSS GeneratorDesign soft UI neumorphic shapes with live preview and copy the box-shadow CSS.CSS Clamp GeneratorTurn min/max sizes and viewport widths into a fluid CSS clamp() value in rem and vw.CSS @font-face GeneratorTurn font files or URLs into ready-to-paste @font-face rules with weights, styles and a preview.CSS Media Query GeneratorBuild @media rules for widths, orientation, dark mode and hover, or get framework breakpoints.CSS Scrollbar GeneratorStyle scrollbars: width, colors, radius and hover, with ::-webkit-scrollbar and scrollbar-color CSS.CSS Sprite GeneratorPack many icons into one sprite sheet PNG and get CSS classes with background-position.CSS Text Gradient GeneratorMake gradient text with background-clip:text: color stops, angle, font preview and fallback CSS.CSS Toggle Switch GeneratorDesign pure-CSS toggle switches: size, colors, shape and animation. Copy accessible HTML + CSS.CSS Tooltip GeneratorBuild pure CSS tooltips: position, arrow, colors, padding and animation. Copy HTML and CSS.HTML Form BuilderDrag and drop form fields with labels and validation, then copy accessible HTML and CSS code.Iframe GeneratorCreate iframe embed code: size or responsive ratio, border, allow, sandbox, lazy load, live preview.PX to VW ConverterConvert pixels to vw and vh for any viewport size, and vw/vh back to px, with breakpoint tables.SVG to CSS Data URITurn SVG code into a small URL-encoded data URI for CSS backgrounds, with Base64 size comparison.SVG to JSXTurn SVG code into a clean React component: camelCase attributes, style objects, TypeScript.HTML Accessibility CheckerPaste HTML to find WCAG accessibility problems with impact level, the failing element and a fix.HTML Image Map GeneratorDraw clickable rectangle, circle and polygon hotspots on an image and get image map HTML.SVG ViewerOpen or paste SVG code to preview it live with zoom, backgrounds, size info and PNG export.Pathfinding VisualizerAnimate BFS, DFS, Dijkstra, A* and greedy search on a grid with walls, weights and mazes.Tailwind CSS Cheat SheetSearchable Tailwind class to CSS reference with live previews, class decoder and color palette.Web App Manifest GeneratorCreate a PWA manifest.json and every app icon size from one image, downloaded as a ZIP.CSS Background Pattern GeneratorMake pure-CSS stripes, dots, checkerboard, zigzag and grid backgrounds and copy the code.CSS Color Filter GeneratorTurn a HEX color into a CSS filter that recolors black icons and SVGs, with an accuracy score.CSS Gradient Animation GeneratorCreate animated gradient backgrounds: pick colors, angle and speed, preview live and copy the CSS.CSS Hover Effects GeneratorPick button, link and image hover effects, tweak colors and timing, and copy the HTML and CSS.CSS InlinerMove CSS from style blocks into inline style attributes so HTML emails render in every client.CSS Shape Divider GeneratorCreate wave, tilt, curve and triangle section dividers and copy the SVG, HTML and CSS.CSS Transform GeneratorRotate, scale, skew and translate an element with sliders and copy the CSS transform code.Font Pairing ToolPreview Google Font heading and body pairs on real layouts and copy the embed code and CSS.
    See all 52 Web, HTML & CSS Tools →