Method for managing computer files in a first device capable of storing computer files, and capable of being connected to at least a second device for exchanging at least computer files, said first device storing the files according to a first data structure representing a first file tree allowing files stored in a memory space of the first device to be accessed, the descendants of the root of the first tree corresponding to a first level of the tree, the descendants of nodes of the first level corresponding to a second level of the tree and so on, the method comprising the following steps: - for a current level of the first tree, receiving data that are representative of a level of the same rank of a second data structure representing a second file tree allowing files stored within the second device to be accessed, the descendants of the root of the second tree corresponding to a first level of the tree, the descendants of nodes of the first level corresponding to a second level of the tree and so on; - comparing the current level with the level of the same rank of the second structure, which level is represented by the received data, in order to determine the presence, in the second tree at the level of the same rank as the current level, of an element which is not present in the first tree at the current level; - in the case that an element of the second tree is not present in the first tree, incorporating a descriptor of this element within the first tree data structure at the current level, said descriptor allowing said element to be accessed from the first tree, wherein, when comparing the levels, it is further determined whether a first element of the first three and a second element of the second tree are identical according to a first comparison criterion, characterized in that, in this case, the following steps are carried out: - comparing the first and second elements according to a second criterion in order to determine whether the first and second elements are different according to the second criterion; and - in the case that the first and second elements are different according to the second criterion, incorporating a descriptor of the second element within the first tree data structure at the current level, said descriptor allowing said second element to be accessed from the first tree, and wherein the first criterion is the name of the element and the second criterion is the memory size or the content of the element. - for a current level of the first tree, receiving data that are representative of a level of the same rank of a second data structure representing a second file tree allowing files stored within the second device to be accessed, the descendants of the root of the second tree corresponding to a first level of the tree, the descendants of nodes of the first level corresponding to a second level of the tree and so on; - comparing the current level with the level of the same rank of the second structure, which level is represented by the received data, in order to determine the presence, in the second tree at the level of the same rank as the current level, of an element which is not present in the first tree at the current level; - in the case that an element of the second tree is not present in the first tree, incorporating a descriptor of this element within the first tree data structure at the current level, said descriptor allowing said element to be accessed from the first tree, - comparing the first and second elements according to a second criterion in order to determine whether the first and second elements are different according to the second criterion; and - in the case that the first and second elements are different according to the second criterion, incorporating a descriptor of the second element within the first tree data structure at the current level, said descriptor allowing said second element to be accessed from the first tree, and wherein the first criterion is the name of the element and the second criterion is the memory size or the content of the element.