Accepted answer

one option is to filter derived resources. in the upper right corner of the 'open resource' dialog there is an arrow you can click to bring up a dropdown menu for filtering. uncheck the 'show derived resources' option, if it is checked.

if you still see '.class' files, they probably aren't being marked as derived. if they're by themselves in their own folder hierarchy you can fix this by right-clicking the root folder to edit folder properties, and check the 'derived' checkbox. if they're mixed with your '.java' files...tough luck, you'll need to set the derived property on each '.class' file by hand.

as far as i can tell there's no way to mark class files as derived resources globally for the workspace, but i believe when you create a new java project the 'bin' folder is marked as derived by default (if you use the default wizard settings)

here are some screenshots from eclipse kepler. the first shows how to filter derived resources by unchecking 'show derived resources' in the open resource dialog. the second shows how to set the 'derived' property on a resource.

enter image description here

enter image description here


showing or hiding files in the project explorer view you can choose to hide system files or generated class files in one of the navigation views. (system files are those that have only a file extension but no file name, for example .classpath.)

on the toolbar for the project explorer, click the menu button menu button to open the drop-down menu of display options. select customize view..,.

in the dialog box that opens, select the filters tab and then select the checkboxes for the types of files that you want to hide. in addition, you can restrict the displayed files to a working set.

enter image description here on the toolbar for the project explorer, click the menu button menu button to open the drop-down menu of display options. choose select working set... select an existing working set from the list or create a new one by selecting new check here


version 3.5 open resource dialog has a way turn "show derived resources" on/off by a small dropdown menu at the top right hand corner. turning it off will hide classes.


you could type an expression on the "select an item to open" text box such as : *.java


some time you are not able mark build or bin folder as derived resource, because eclipse package explorer or project explorer does not show you build or bin folder in project view.

what you need to do, to show build folder in project view:

  1. go to project > properties > java build path > source > change default output folder to build1 note: it will ask you to remove old folder and its content, press no (to restore it later)

  2. now build folder is visible on package explorer, go to folder properties and mark it as derived

  3. now change your default output folder back to build (to restore old setting)


eclipse luna - just go to the following link
1. create a working set (include all projects)
2. on "package explorer" panel click on "filters" (in the same menu you just created the working set) and deselect "inner class files" + click ok

that worked for me


to solve this globally (on all projects), after pressing ctrl + shift + r, click on the top right corner of the window on the three dots button, then click on select working set, tick both java main source and java test source and voila.


you can use working sets. from the same dropdown menu on open resource dialog select select working set. it opens up the working set dialogue where you can create working sets if you don't already have them.

when creating a new one, choose the type resources and select which folders in your workspace are consider as candidates for searching or for opening resources. i have included only src and test folders and usually pom.xml's and other misc configuration files.

with the couple of large projects i'm working on it has a noticeable impact on search speed too.


to change this behaviour and hide the “.class” files you need to do the following.

  1. find your class output folder in the “project explorer” window. this is usually called bin or target for maven projects

  2. right-click this folder and click properties

  3. tick the derived checkbox (leave it unchecked) and click ok

.class files will now be hidden in future.



  1. right click on the project and select properties enter image description here
  2. expand resource and click on resource filters
  3. click on add filter... to create a new filter enter image description here
  4. on the dialog box that opens
    1. select the exclude all and files radio buttons
    2. under file and folder attributes enter *.class
  5. click ok

enter image description here

to exclude an entire directory hierarchy, e.g. the target directory, select the files and folders radio button and the all children (recursive) checkbox.


exclude the following for a complete cleanup of open resource dialog

  1. files *.class
  2. folder bin
  3. folder build
  4. folder target

without excluding all 4 it does not work.

Related Query

More Query from same tag