Get file ID in figma plugins

Hello Figma,

Is it possible to add a way to get file ID in the plugin API? My team and I have developed a couple of plugins for clients that enhance collaboration or workflow automation. We have had a few use cases for this feature including the following:

  1. Collaboration: A plugin wants to keep records of elements belonging to a particular file and later when a user loads the plugin, we want to check what file the user is in so we can show them the said elements for that file or throw an error if it’s a wrong file.

  2. Workflow Automation: Plugins automating repetitive tasks use file IDs to remember and apply settings or changes to the right file consistently.

Currently, we have been solving this by asking users to provide their file URL so as to extract the file ID of the file they are currently running the plugin which does not provide a good user experience I would say.


You can only access a Figma file’s key from within a plugin if the plugin is privately published. I don’t think the Figma team has any plans to change this as of now.

Hi Simon, thanks for your response. I am aware of this that’s why I published my post as a feature request. I don’t think your response solves the issue so it makes sense if the post remains unsolved.

Hey @neicore, @Simon_Steer’s reply is correct.

fileKeys are only available to private plugins, due to our legal guidelines. We cannot allow just anyone access to files that they did not create or do not have a license to use for a public plugin.

If you want to explore a pathway to become eligible for fileKey access, please email us at with more details, so our community team can get a better understanding of your plugins.


thanks @dvaliao, understood.