Method and system for searching for useless file

The embodiment of the invention provides a method and system for searching for a useless file. An older-version application program installation directory meeting an installation directory feature corresponding to the application program in a preset feature library besides the installation directory in the parent directory of the application program installation directory obtained according to a registry, and the useless file is searched for in the searched older-version application program installation directory. Due to the fact that the new-version and older-version application program installation directories generally have a certain installation directory feature, the older-version application program installation directory can be found through the installation directory feature, and therefore the useless file is searched for in the older-version application program installation directory. Therefore, according to the method and system for searching for the useless file, the useless file search effect is improved, the situation that the useless file in the older-version installation directory exists in terminal equipment for a long time and occupies the disk space is avoided, and efficient operating of the terminal equipment is effectively guaranteed.