Skip to main content
marcinukleja
New Participant
December 27, 2023
Solved

Paste SVG code no longer available

  • December 27, 2023
  • 2 replies
  • 1067 views

I recall that Figma previously supported pasting SVG elements that were copied as raw code. I used to copy these elements from the inspect panel in a browser and paste them into Figma, where they would be rendered perfectly as vectors.

It appears that this feature is no longer available, which is disappointing as I found it very useful. Is there any possibility of bringing this feature back?

    This topic has been closed for replies.
    Best answer by marcinukleja

    I’ve figured it out! The issue was with the SVG element I was trying to copy: it had an extra apostrophe before the xmlns attribute.

    For example, I attempted to copy the following code (it represents a text layer icon in Figma):

    <svg class="svg" 'xmlns="http://www.w3.org/2000/svg" width="10" height="10" viewBox="0 0 10 10"><path fill="#000" fill-opacity="1" fill-rule="nonzero" stroke="none" d="M0 0h10v3H9V1H5.5v8H7v1H3V9h1.5V1H1v2H0V0z"></path></svg>
    

    After removing the apostrophe in front of xmlns , the code worked perfectly. The next step for me is to find a way to ensure that the code is copied correctly in the first place, without these extra characters.

    2 replies

    marcinukleja
    marcinuklejaAuthorAnswer
    New Participant
    December 27, 2023

    I’ve figured it out! The issue was with the SVG element I was trying to copy: it had an extra apostrophe before the xmlns attribute.

    For example, I attempted to copy the following code (it represents a text layer icon in Figma):

    <svg class="svg" 'xmlns="http://www.w3.org/2000/svg" width="10" height="10" viewBox="0 0 10 10"><path fill="#000" fill-opacity="1" fill-rule="nonzero" stroke="none" d="M0 0h10v3H9V1H5.5v8H7v1H3V9h1.5V1H1v2H0V0z"></path></svg>
    

    After removing the apostrophe in front of xmlns , the code worked perfectly. The next step for me is to find a way to ensure that the code is copied correctly in the first place, without these extra characters.

    ksn
    Figmate
    Community Support
    December 27, 2023

    Thank you for the update @marcinukleja ❤️ let us know if any other questions or possible issues come up!