0

I'm working a lot with Scalable Vector Graphics (SVG) code and need some help. How do I export SVG code to a file? Do I have to use a program outside of my text editor to do this?

  • 1
    You just save it. SVG is just a text file (a kind of XML actually), with an svg file extension. – Billy Kerr Aug 2 at 10:56
  • @BillyKerr so the opening and closing tags are <svg></svg> ? and then save it as .svg? – Daniel Aug 2 at 11:35
  • Yes, that's it. Note: if your text editor doesn't allow you to "save as" SVG, just save it as a regular text file (.txt), and change the file extension to .svg – Billy Kerr Aug 2 at 11:50
  • @BillyKerr i just did that but no image shows when i open it... – Daniel Aug 2 at 11:54
  • What are you opening it in? Drag the file into your browser. If it's a valid SVG, it should display. – Billy Kerr Aug 2 at 11:57
2

An SVG file is just a text file (actually an XML file), much like an HTML page. It contains a set of instructions which can be read by software (such as a browser) and displayed or rendered as a graphic on-screen.

All you need to do is save your SVG file as a .svg file. If your text editor doesn't allow you to save as .svg, you can save it as a regular text file (.txt) and change the file extension to .svg

If you want software to open and edit an SVG graphicially, you can use vector image editors, such as Inkscape, or Adobe Illustrator.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.