How retain folder structure, when sharing subfolders?

As Admin, if I share a subfolder (within a folder structure) to a user with a registered account on my server, I want the browsing experience for the user to retain the existing folder structure, regardless of what I share or don’t share. But I’m having problems understanding how to achieve this. Could use some help.

An example: Imagine the following folder- and subfolder structure:

[Toplevel Folder]
----- > [Subfolder A]
---------- > [Subsubfolder B1]
---------- > [Subsubfolder B2]
---------- > [Subsubfolder B3]
----- > [Subfolder B]
---------- > [Subsubfolder C1]

If I share only “Subfolder B2” with a user on my server, and this user have no other rights, then this user will see only a new folder in his folder list, called “Subfolder B2”.

This is both confusing an visually displeasing in my view. I will want the user to see the toplevel folder, and when he goes into that folder I want him to see the folders called Subfolder A (but not subfolder B, because he haven’t got access rights to anything under that folder). And when he goes into Subfolder A I want him to se one folder called Subfolder B2 (but not Subfolder B1 or B3, because he doesn’t have access rights to those).

Is there some setting, or code or customization which enables this, o allows me to create this condition somehow?
And I prefer to use regular sharing instead of group folders, because group folders seems to have a file upload bug that isn’t addressed.

Thanks for any help

1 Like

Thanks for response @tflidd.

Yes, the group folder option would’ve solved a lot. But I feel it’s not open to me at this time.

Using group folders seems to introduce a bug, or at least incompatibility, and there seems to be no fix for it in sight. I ran into this strange behaviour myself when I tried the group folder option and it’s either a straight up bug or incompatibility with the file encryption system.

The bug prevents- or complicates user’s ability to synchronize and/or upload files into shared folders and group folders. (

If there was a solution for THAT, I’d be on the Group Track train instantly.

It continues to be amazing for me how people are stuck on the traditional, hierarchical representation of folders and files. Why do tags not serve the same purpose for you?

Group Folders will continue to have its challenges, fully agree with you. But why is it not possible to embrace the advantages of the flexible sharing system provided and use tags and other meta data for a description of whats in the folder?

@Escubaer Well, I can hear the frustration there :slight_smile:

The problem I see, is that I use folders to organize things into categories. If a folder is named “Contracts”, then whoever enters into it knows that all titles he will find inside there are only contracts.

----------Annas deals
----------Bobs deals
----------Archived deals

If a subfolder under contracts is called “Archived deals”, then we already know it is archived contract deals, and then in the next subfolder level we got years. Having the folders labelled and organized like this, means you affects the users ability to instantly know and sort what he/she is looking at. And I don’t have to write all of this into the file name, making file/folder names half a city block long.

But if I share the 2018 folder with a user, and no previous folder structure is inherited, then this user won’t see the context from which to understand thje folder. No “Documents”, nor “Contracts” or anything beneath … he won’t see or understand anything, other than that he now have a folder in his root directory, called “2018”. That’s no good.

One workaround for that, would be to name every folder the full context name: Documents.Contracts.Archived.Deals.2018. The bad idea with this, is that users who have access to plenty of folders will see every shared folder as a separate folder, meaning a long long row of independent folders all in his root directory with no sorting other than folder name first letter sorting.

This is a big part of why I feel I can use the folder structure intact even when I share a subfolder.

You said “Why is it not possible to embrace the advantages of the flexible sharing system provided and use tags and other meta data for a description of whats in the folder?

You may know more about this than I do. You are right in the sense that I did grow my sense of organization from looking into a DOS prompt, then Windows File Explorer and running an FTP server for a while. I frankly am not sure how you mean by ‘using tags and metadata’ in place of folder names …? Maybe you know something I don’t know about Nextcloud’s options, and I’m all ears (no sarcasm).

1 Like

You could give all the files or the folders a “contract” tag to serve the same purpose.

And in the folder description you can write that its contracts, that is a file which is moving inside the folder along with it …

I fully understand the issue, when using traditional folder structures, but thats why I recommend to leverage the features of the platform …

If you have no problem with long names, you can perhaps use this names for sharing folders from admin:

>     ----- > [A]
>     ---------- > [A - B1]
>     ---------- > [A - B2]
>     ---------- > [A - B3]
>     ----- > [B]
>     ---------- > [B - C1]

@Escubaer Ok. I think I see your point. Though I must say can’t say I see many benefits with it - at all, frankly. Since you said you can’t really understand why some people is reluctant to tag and labels for organization, I can write a few of these points out for you:

If no folder structure is deemed beneficial, then one might as well just throw all files (documents, PDFs, images, videos) into 1 folder, call that folder “Files”, and never go into that folder visually, right? Just search out the desired files using tags?
But if a folder structure is beneficial, in any way at all, then one might as well use that for orientation instead of tags.
That way I also won’t be dependent on however users actually remembered to tag their files or not, or if they misspelled their tags or put the wrong type of tags in etc. I mean, users will have to tag an audio file “audio”, even though the file extension (wav, aif, mp3 etc) is already searchable. There are way too many open doors for errors to slip in through that way.

How do you use versioning with tags? Since a document can only be found by tags, you’d have to add the version as a new tag too, right? Press-release, Press-release update, press-release update 2, press-release update 3 etc. It begs for mistakes too.

Folders also give you a way of exploring visually, going through and building the same idea of a structure in your head as the other users/personnel have, so you can speak on the same terms with others. Searching using tags won’t give you that. It’s more like operating a command prompt, you get no sense of structure or organization, just a different row of resulting files depending on how you formulate a search term.

And you won’t actually know if there are physical files out there, in the unknown cyberstorage, that haven’t been tagged properly and therefore lies forgotten, virtually invisible (to a tag search). With a folder system, you visually see all files. But with a tag system you only see what is tagged, and only if they are tagged properly too. You may have tons of rouge forgotten files around without knowing it.

Tags makes it hard for a new user too, who cannot know what to search for. They are not familiar with what tags and label to search for, what the present term-system is. I would have to give them a glossary of terms/tags which will provide them with desired results. And I would have to teach them how to save tags into all newly created files too.
With a folder system for organization, not even a 7-year-old needs any form of introduction. It is infinitely less BS, intuitive and direct. Using folders for orientation is using our eyes, the sense we use for 90% of our informational intake. It’s why Microsoft upgraded DOS into visual Windows, to interact with the computer though. Tags however, uses almost no visuals, and almost only memory.

Sharing files with other becomes equally difficult. If you store files with no folder structure, and you are then asked to share all files of a specific concern with a specific user, (different files types too) , you’d probably have to go through each concerned file and share it one by one. And as a result, the other user will then see lots of separate files (the shared files) in his root directory, with no visual structure and under no folder.
With a folder structure however, the structure is already in place. All you do is share the concerned folder, and the other user will see the same thing as you. Done.

Those are a few of the problems I see with using a tag system instead of a folder structure, and why I don’t find it beneficial to use. Tags may be used as a complement though.

I am currently back experimenting with different encryption options, so I can perhaps somehow use the Group Folder option anyway. Group Folders make it rather easy to maintain the existing folder structure even through sharing, but Group Folders don’t work well with different storage encryptions, even though I plan to store everything on site and not use external storage.


Can you search tags on your local synced files? As far as I was aware this wasn’t possible.

As a relatively new user to Nextcloud (who has used Owncloud for a long time), I’d like to thank @Clarion for clearly articulating this problem and that tags are not an acceptable workaround.

Sharing subfolders results in their showing up at the top-level in user accounts that have access to the share. And if shared subfolders have the same name, it is not possible to distinguish them. For example, assume the following directory structure:


If both of the above sub folders are shared, they show up as the top-level folders:

sub (2)

This is not good.

Consider the larger case where someone receives shares from within their organization and from external nextcloud users. It will become increasingly confusing to have these various shares show up at the top-level directory.

Here’s what I suggest:

  1. Because shares can come from the organization’s own nextcloud server or some external nextcloud server, it is necessary to have a top-level entry that identifies the organization server. This should be the FQDN of the nextcloud server.

  2. Because shares can come from various users, the 2nd level directory should be the username of the user granting the share.

  3. Because the shared folder can be a subfolder, the remaining directory levels to the share should be preserved to the user receiving the share by default. With (1) and (2) in force, I can envision an option during sharing in which the user can choose to omit the full path. But, this should not be the default as even a single user in a single organization might share subfolders of the same name.

For example:… # userA has 2 “sub” folders to share… # userB has only 1 “sub” folder to share and elects to not use the full path… # default full path… # default full path not chosen

It is reasonable to offer the option of not using full paths if it is the case that full paths would reveal company information that would not want to be disclosed and if multiple paths are distinct.

Another modification of this approach is to provide an option in which a share prefix can be explicitly entered during sharing so as to provide appropriate context while at the same time not revealing company private information that a path might otherwise convey.

1 Like

I share the same concern. I finally choose the suffix option as a workaround.
The department name is the suffix.

  • companyA_accounting
  • companyB_accounting
  • companyA_marketing

1+ for this feature.

I’m working in a movie production company and we have a folder structure like this:

So what I wish to do is to share the needed shots folders to the vfx artist that will work on them and the needed plates folder, say the explosions folder.
That way everyone won’t access all the footage and all the plates as that can be sort of a security issue.

While still keeping the full folder structure it will be easy to just add/remove access to different folders and who ever will get the folders in the end it will look the same for everyone.
So a feature like this would be more than welcome for a workflow like this.

Hi, the recommended way is to use the groupfolders app for this:

@szaimen The groupfolders app is not a scalable solution. Requiring admins to manage sharing is not reasonable. Nextcloud should offer the ability to share files and folders in a way that does not lead to ambiguity. See my post on Feb 13, 2021.

The Nextcloud platform has sharing as a core feature: it needs to be improved to avoid ambiguity. I am open to working with Nextcloud on an implementation design.

Delegation for groupfolders comes with NC23, afaik.

@szaimen If delegation still requires admin setup, then it is not an acceptable solution. Users need to be able to self-service their sharing needs. Also, not addressed is the significant issue of how ambiguities are resolved. If multiple people want to share a folder terminating in some identical name, it is important that shares be done in a way that lends itself back to understanding of who shared them, etc. See my post above.

No, delegation means that also selected non-admin users will be able to create groupfolders etc, afaik.

Also see this PR: Implement Admin delegation for group folder by CarlSchwan · Pull Request #1722 · nextcloud/groupfolders · GitHub

Group folders is also not really working for me. A real solution would be highly appreciated! :smiley:

1 Like

Hi @Clarion thank you very much for the great formulation of the problem as well as its defense. As long as this challenge remains unsolved, Nextcloud is not yet practicable for us. I hope that something will happen here soon. Here there is still a possible solution approach via Groupfolders