Skip to main content
Anton_Bahrencheer
New Member
June 21, 2023

LAUNCHED: Moving or copying variables

  • June 21, 2023
  • 73 replies
  • 53056 views

Has anyone found a way to copy, transfer or move the new local variables to another file or collection?

Just created around 400 color variables manually in the wrong file and would hate having to re-create them in the correct one 😅

73 replies

Oliver_Schwaiger
New Participant
January 10, 2024

Thanks @Bencko_Jan & @Hal_Lee.

Quick question as I do not only want to copy and paste variables between files, It is super important for me that all linked variables in all files will stay synced with the variables. Not to create another copy of them.
Is this something that your plugin can do? Then I would love to try it out. But as I am working on a library connected to tons of files, I have to be very careful.

Bencko_Jan
January 10, 2024

Maybe just create a new Design system containing the variables you need and connect that design system to the files where you need to need to use the variables.

Bencko_Jan
January 10, 2024
Oliver_Schwaiger
New Participant
January 10, 2024

Thought about that already if you mean Figma libraries. But it feels like a rather messy approach to me.

Hal_Lee
New Member
January 11, 2024

I found this plugin that can replace variables but you need to replace one by one.

Figma

I plan to support swapping variables by variables matched in my plugin later.

Oliver_Schwaiger
New Participant
January 11, 2024

Thanks for that @Hal_Lee , will test it 😉

Deepti_Sharma
January 31, 2024

This is what it says in their guidelines

Copy pasting variables across files

Variables can be used in prototypes.

Currently, if you copy and paste objects to different file, the prototype will continue to work as the variables transfer over. However, any unpublished variables applied to prototypes won’t be available for further use, like when creating Set variable actions, or switching an object’s number variable.

We are working on improving transferring variables across files. As a workaround, either recreate the variables in the destination file, or duplicate the original file.

If the original file is published to team libraries, copied and pasted variables will work as expected.

If you receive a notification that pasting unpublished variables across files won’t create new local variables yet, try publishing the source library and and enabling it in the destination file.

Celine_
Figmate
Community Support
February 28, 2024

Hey everyone,
To give you an update, with the launch of some new Figma Prototyping updates, you can now copy and paste local variables: when copy and pasting an element with a local variable bound to it, Figma will create a collection with the new, copied variable so it can be used freely in the new file. You can learn in our Help Center article here. Hope this helps!

Oliver_Schwaiger
New Participant
March 1, 2024

Hey @Celine_Figma nice that this feature is launched.
I am however wondering if it is possible to move variables from one library to another one.
Like you are able to move already published components to another library by cutting them out and pasting them in the new file. After publishing them inside the new file, all linked instances will remember their master and know it‘s been moved. Therefore no link will break.

I basically want to do the same thing with variables.
Will this be possible anytime soon-ish?

Celine_
Figmate
Community Support
March 1, 2024

Hey Oliver, thanks for your feedback! To be transparent, it’s not on our immediate roadmap at the moment but, it’s definitely on our radar for improvement.
I’m happy to pass your feedback to the team to give them visibility, though I can’t guarantee an ETA for any improvements. Thank you!