Photoshop: Delete all unused layers in ALL layer comps feature.

11 Votes
LEGEND ,
Sep 09, 2011 Sep 09, 2011

Copy link to clipboard

Copied

Delete all unused layers in ALL layer comps. Right now hitting delete all unused layers messes up a file with more than 1 layer comp. Personally I use like 20 layer comps each PSD - this feature would help immensely in trimming file size down and cleaning up if handing the file off.
Idea No status

Views

475

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
16 Comments
Adobe Employee ,
Sep 09, 2011 Sep 09, 2011

Copy link to clipboard

Copied

Can you describe "messing up" Corrupts, messes up layer order, etc..

Thanks.

Votes

Translate

Translate

Report

Report
LEGEND ,
Sep 09, 2011 Sep 09, 2011

Copy link to clipboard

Copied

Think of it as a 3-layered wedding cake. If I highlight layer comp 1 (the top of the cake) and hit the current "delete unused layers" I will actually delete everything not pertaining to layer 1. Layer comp 2 and 3 of the cake are now deleted. Not good. I would like to select 1,2 and 3 layers of the cake and now hit delete unused layers to clean it up to ship without any danger of deleting anything I need.

Votes

Translate

Translate

Report

Report
LEGEND ,
Nov 01, 2013 Nov 01, 2013

Copy link to clipboard

Copied



Hi, I am an Interface Designer and therefore working every day with Adobe Photoshop.
By my experience with this program, some suggestions for future developments grew in my head, which I now want to communicate.
1. It would be very nice and helpful to handle the normal layers with the help of 'layer compositions'.
When I created many layer compositions, I always lose control of the structure of the normal layers and then I yearn for a function like: 'mark all normal layers, that belong to this layer composition.'
2. It would also be nice to be able to delete layers, that are not part of a layer composition.
Kind regards,
Linda

Votes

Translate

Translate

Report

Report
LEGEND ,
Nov 01, 2013 Nov 01, 2013

Copy link to clipboard

Copied

yes i'd like a option to get rid of all empty layers.

Votes

Translate

Translate

Report

Report
Adobe Employee ,
Nov 01, 2013 Nov 01, 2013

Copy link to clipboard

Copied

File>Scripts>Delete Empty Layers... will do that.

Senior Product Manager - Customer Advocacy - Digital Imaging

Votes

Translate

Translate

Report

Report
Valorous Hero ,
Nov 02, 2013 Nov 02, 2013

Copy link to clipboard

Copied

There is a script here to remove all layers not used in any LayerComps
http://www.ps-bridge-scripts.talktalk...

Votes

Translate

Translate

Report

Report
Adobe Employee ,
Nov 02, 2013 Nov 02, 2013

Copy link to clipboard

Copied

Cool! Thanks Paul.

Senior Product Manager - Customer Advocacy - Digital Imaging

Votes

Translate

Translate

Report

Report
LEGEND ,
Dec 19, 2014 Dec 19, 2014

Copy link to clipboard

Copied

thanks a lot.. it worked perfectly 🙂

Votes

Translate

Translate

Report

Report
LEGEND ,
Jan 02, 2015 Jan 02, 2015

Copy link to clipboard

Copied

Scripts scare me, so I found a really freaking easy workaround:

1. Filter layers list to Attribute = Not Visible
2. Select all the matching layers
3. Cycle through all layer comps
4. Layers still selected aren’t used in any layer comp

Delete the layers that are still selected. Bingo bango. With keyboard shortcuts for navigating layer comps, this takes like 7 seconds or something.

Votes

Translate

Translate

Report

Report
Community Beginner ,
Jan 12, 2016 Jan 12, 2016

Copy link to clipboard

Copied



Would love to have the ability, in the layer dropdown menu, to delete empty layers (no pixels) and also delete unused layers. The unused layers would be based on whether the layers are used in any layer comps. (love layer comps BTW).

Votes

Translate

Translate

Report

Report
Community Beginner ,
Jan 12, 2016 Jan 12, 2016

Copy link to clipboard

Copied

Good point but I often have documents with 20 or more layer comps. Makes the process pretty tedious. I think that a simple "delete unused layers" would be easy enough to hook up to the layer dropdown menu. :)
Cheers.

Votes

Translate

Translate

Report

Report
LEGEND ,
Jan 13, 2016 Jan 13, 2016

Copy link to clipboard

Copied

Same (20 or more layer comps). That's why I'm such a keyboard ninja with them. So still this doesn't take long. Still still, a native solution like you suggest would be nice.

Votes

Translate

Translate

Report

Report
Community Beginner ,
Jan 13, 2016 Jan 13, 2016

Copy link to clipboard

Copied

Just tried your trick and it works great.
Still want the simple menu command but until then this will do :)
Thanks for the tip!

Votes

Translate

Translate

Report

Report
LEGEND ,
Apr 07, 2016 Apr 07, 2016

Copy link to clipboard

Copied

Thank you so very much!

Votes

Translate

Translate

Report

Report
LEGEND ,
Jun 11, 2018 Jun 11, 2018

Copy link to clipboard

Copied

actually if you click the hamburger menu on the Filter part, there is a "Delete Hidden Layers" option.  I created an Action using it! Finding out about the Attribute Filter was fantastic though! Thanks!

Votes

Translate

Translate

Report

Report
LEGEND ,
Apr 11, 2019 Apr 11, 2019

Copy link to clipboard

Copied

LATEST
Good news everyone! I created script for removing layers not used in any layer comp. Download here: https://bereza.cz/ps/

  • Locked layers are skipped (unlike built-in feature Layer > Delete > Hidden Layers)
  • Works with and without layer compositions
  • Super fast. Thousands of layers in few seconds. Should be much faster than any other scripts.
  • Also handles clipped layers



Votes

Translate

Translate

Report

Report