PDF to SVG converter

Choose a PDF, pick a page, and download an SVG made of the page’s own vector paths. Text becomes outlines where the PDF carries its fonts, and anything left out is listed beside the result.

Free, no account. The file is read by code running in your browser. It is not uploaded, and nothing about it is stored.

or drop it here, or paste

How to convert a PDF to SVG

  1. Choose your PDF or drop it on the box.
  2. If it has more than one page, pick the page with the arrows or type its number.
  3. Compare the two pictures: the page as a PDF reader draws it, and the SVG.
  4. Check the notes for anything the SVG does not hold, then download it.

What comes across

A PDF page is a list of drawing commands: build a path, fill it, stroke it, clip to it, show some text. This tool reads that list with pdf.js, the open-source PDF reader made by Mozilla, and writes the same paths into an SVG. The page is never turned into pixels, so nothing is traced or blurred.

  • Every filled and stroked path, with its Bézier curves kept as curves, placed to a thousandth of a point.
  • Fills: the colour, the opacity and the fill rule, so shapes with holes keep them.
  • Strokes: colour, opacity, width, round or square ends, round or bevelled corners, the mitre limit and dashes. A line of zero width, which in a PDF means the thinnest line a device can draw, is written as a line one pixel wide at any zoom.
  • Transforms: every matrix is worked into the numbers of the paths, so the SVG’s shapes lie where they are drawn. The one exception is a line drawn under a lopsided matrix, thicker one way than the other, which keeps its matrix so that it looks the same.
  • Clipping paths, one inside another as the PDF nests them. A clip that covers the whole page, which most PDFs begin with, is dropped as it does nothing.
  • Gradients that run along a line or out from a point become SVG gradients.
  • Layers: shapes on a layer that is switched off in the PDF are left out, as a PDF reader leaves them out.

Text and fonts

Text in a PDF is stored as character codes and the name of a font. Most PDFs also carry the fonts themselves, or the parts they use. Where the font is in the file, every letter is written as its outline, in the right place, size and colour, and each run of text becomes one path. The words can no longer be edited as words, but they look the same on any device and can be cut or engraved.

Where the font is not in the file, there are no letter shapes to copy. PDFs often leave out the standard fonts every reader is expected to have, such as Helvetica, Times and Courier. That text is left out of the SVG, and the notes name the fonts. The same goes for Type 3 fonts, whose letters are small drawings of their own, and for the invisible text layer a scanner lays over a picture of a page.

What is left out

Pictures are left out: photographs, scans and stencil masks are made of pixels, and this page converts vector shapes only. A PDF that is a scan of a drawing is one big picture, so the SVG would be empty; the page says so, and the picture needs tracing instead with the PNG to SVG converter.

Also left out, each counted in the notes: mesh gradients and tiling patterns (the shape is kept, without that paint), soft masks, blend modes such as multiply, text used as a clipping path, and annotations such as sticky notes, stamps and form fields, which lie over a page and are not part of it. A see-through group has its opacity given to each shape in it, which looks darker where those shapes overlap.

Colours are written as RGB. Greys, CMYK and the other colour spaces of a PDF are converted by pdf.js, so a CMYK red can look a little different here from the red your PDF reader shows. A PDF locked with a password is refused.

Size, units and the page

PDF measures in points, 72 to the inch. The SVG’s viewBox is the page in points, with 0, 0 at the top left, and its width and height are the same size in millimetres: an A4 page gives a viewBox of 595.28 × 841.89 and a size of 210 × 297 mm. A page that the PDF turns on its side is written the way it is shown, turned. The paper itself is not drawn, so the SVG has a transparent background unless the PDF paints a white rectangle.

One page is converted at a time. From a PDF of several pages the file is saved with the page number in its name, such as plan-page-3.svg.

PDF to SVG for a Cricut, a laser or a plotter

Cut files and patterns are often sold as PDFs. Converted here, each shape of the PDF is one <path> in the SVG with its own fill and stroke, in the order the PDF paints them. Two things are worth checking before cutting. First, the count of clip paths beside the result: a clipped shape is stored whole with a clip path round it, and cutting programs differ in whether they honour that. Second, white shapes: a PDF often hides things by painting white over them, and a blade cuts along every outline whether it shows or not. The SVG viewer with its dark background shows them.

Questions

Why does the page say there are no vector shapes?

The PDF page is a picture: a scan, a photograph or a screenshot saved as a PDF. There are no paths in it to convert. Save the page as a PNG from your PDF reader and trace it with the PNG to SVG converter.

Why is the text missing from my SVG?

The PDF does not contain the font, so there are no outlines for the letters. The notes beside the result name the fonts concerned. If you made the PDF, export it again with fonts embedded, or convert the text to outlines before exporting.

Can I convert every page at once?

No. Pick a page, download it, then pick the next. Each page is saved under its own name.

Is the SVG an exact copy of the PDF?

Of its vector shapes, as near as the numbers allow: pdf.js holds path points as 32-bit numbers, about seven significant figures, and they are written to a thousandth of a point (letter outlines to a hundredth). What is not copied is listed above and counted in the notes for your file.

Can I edit the SVG afterwards?

Yes, in any vector editor. Shapes are ordinary paths. Text that was turned to outlines is shapes too, so it can be recoloured and resized but not retyped.

Related