How to remove deleted variables that are still attached in Figma

A step by step guide on detaching or removing ghost variables (i.e. deleted variables that are still being used) from a Figma Design File.

Oscar de la Hera Gomez
Written by Oscar de la Hera Gomez
First published on 09/06/2023 at 12:48
Last Updated on 09/06/2023 at 13:24
<p>A flower that represents Figma with the text "Detach Deleted Variables" beneath it.</p>

A step by step guide on detaching or removing ghost variables (i.e. deleted variables that are still being used) from a Figma Design File.

SubscribeCheck out our Figma Variables GuideCheck out our Figma Resources Guide

The following tutorial walks you through the example of a text UI element that makes use of a string variable that is then deleted.

<p>A screenshot that shows the variables window and a Text UI element with a variable attached. Highlighted is how the variable that is attached is about to be deleted.</p>
How to create a Variable in FigmaHow to use a String Variable in FigmaHow to delete a variable in Figma

Step One: Select the UI Elements

<p>A screenshot of Figma showing a selected text UI element. Highlighted on the right menu side bar is how a variable that no longer exists is still attached to it.</p>

At the time of writing this article, you can only delete variables for UI elements that you select and detach the variables from.

To detach all deleted variables, press Command + A to select all the UI elements of a page in Figma and continue to the next step.

Step Two: Detach Deleted Variables

<p>A screenshot of Figma that shows the Quick actions window that appears when you press command + P. The search bar shows that "detach" has been typed and highlights the "detach deleted variables" menu option - click it to delete the variables on the selected UI elements.</p>

Press Command + P to open up the Quick Actions search bar.

Type in Detach and select Detach deleted variables.

This will remove the deleted variables from the select UI elements and only the selected UI elements.

<p>A screenshot of Figma showing how the deleted variables are no longer applied to the text UI element. It also highlights the alert that appears at the bottom of the screen informing you of how many deleted variables it detached.</p>

Frequently Asked Questions (FAQ)

How do I delete all the deleted variables ?

On each page:

  • Press Command + A to select all the elements.
  • Press Command + P to open Quick Actions.
  • Search for Detach.
  • Click Detach deleted variables.

Looking to learn more about things you can do with Variables or Figma ?

We recommend you check out our Figma Variables Guide or search our blog to find educational content on learning how to use Figma.

Check out our Figma Variables GuideSearch our Blog

Any Questions?

We are actively looking for feedback on how to improve this resource. Please send us a note to inquiries@delasign.com with any thoughts or feedback you may have.
SubscribeContact UsVisit our BlogView our ServicesView our Work

Partner with us

We would love to get to know you and see how we can help your organization with its goals and needs.
Let's Talk

Stay Informed

Get occasional updates about our company, research, and product launches.
Subscribe