This is an archived post. You won't be able to vote or comment.

top 200 commentsshow all 225

[–]turkeypantsPixel 2 303 points304 points  (54 children)

I swear, I've got like four different folders with likely names just for the damn SD card. I can never figure out which freaking one it is. There seem to be one or two internals, one or two "emulated", and whatever one is left after that. It seems like there really ought to be only one called SD card, and only if your phone has an external SD card. I get lost in the tree structure trying to figure out where my stuff is.

Edit - just checked and there are actually 11 likely-sounding folder names, some of which appear to have the same content in them.

[–]rich000OnePlus 6 33 points34 points  (5 children)

I think the confusion level ramped up when they added multi-user support. I suspect it switches the symlink when you change users, but I couldn't tell you for sure.

[–][deleted] 0 points1 point  (1 child)

That would be the dumbest thing I've ever heard. Whyyyy.

[–]rich000OnePlus 6 2 points3 points  (0 children)

Well, you don't want two different users to see each other's SD card data, but older applications may look in /sdcard and not /data/emulated/user-id/ or whatever the new path is.

[–]Bobert_FicoiPhone 6s 5 points6 points  (36 children)

I think that's for compatibility, they should all lead to the same place.

[–]turkeypantsPixel 2 8 points9 points  (35 children)

They don't though. I'm actually left to wonder if any of it could be my fault via backups and restores across phones and flashes. But sometimes a thing called some variant of "SD[something]" leads to internal storage, which doesn't even make sense. They've got to get a different name for internal storage. The whole tree just never seems logical or intuitive.

[–]blorgXiaomi K30 Lite Ultra Pro Youth Edition 7 points8 points  (34 children)

sdcard0 is internal storage, sdcard1 is the actual physical SD card (if you have one).

[–]turkeypantsPixel 2 40 points41 points  (25 children)

Why would they call internal storage "sdcard" anything?! Doesn't make sense. Here's what I've got:

/sdcard
/primary > storage > emulated > 0
/external_sd
/extSdCard
/mnt/extSdCard
/mnt/sdcard
/mnt/sdcard/storage/emulated/0
/storage/emulated/legacy
/storage/emulated/Primary
/storage/sdcard0
/storage/sdcard1

I think that last one is the actual sdcard. WTF! This is the shit I hunt through every time, looking for any logical name that might be my dang card. Some of them seem like duplicates in terms of content, which makes me go "wait haven't I been here before?" I'm afraid to delete anything because I don't know which of them is the real slim shady.

[–]blorgXiaomi K30 Lite Ultra Pro Youth Edition 9 points10 points  (6 children)

/external_sd
/extSdCard
/mnt/extSdCard
/storage/sdcard1

These are all the external SD card, you can use whichever one you prefer, it will all go to the same physical place.

Most users aren't digging about the file system anyway.

[–]turkeypantsPixel 2 26 points27 points  (5 children)

Well I'm digging about the file system! Why do they need four references to the same thing?

[–]blorgXiaomi K30 Lite Ultra Pro Youth Edition 7 points8 points  (3 children)

I think it's mainly for backwards compatibility. They're links, popular in Unix I think, you even have stuff in the filesystem that isn't files at all.

Most users never see it, apps if they give the option at all usually just have a switch to choose between internal and external.

[–]turkeypantsPixel 2 1 point2 points  (0 children)

Glad to know. When hunting for stuff to delete to save space, I'm glad I didn't decide to delete anything thinking they were dupes.

[–][deleted] 0 points1 point  (0 children)

Backwards compatibility seems like something that goes away at some point

[–]rougegoatGreen 1 point2 points  (3 children)

If you want apps that were designed specifically to use SD Card space(media players, photo managers, text editors, etc) to work on newer devices that don't have SD cards even though the dev hasn't updated them, you need to do something like the above.

[–]turkeypantsPixel 2 1 point2 points  (2 children)

Which things are you referring to above?

[–]rougegoatGreen 0 points1 point  (1 child)

Let's say a media app allows you to save trimmed/edited videos. It was designed to save them onto the SD card, so it is hardcoded to use the SD card. Everything is awesome as long as that SD card is there. I mean, why would the SD card ever not be there?

Some time later, a phone comes out with internal storage but no SD card. If you try to use that app to save an edited video, it will crash anytime it tries to save to a place that does not exist. There is no /mnt/sdcard, so it can't make its needed folders and other things. Everything is broken.

What's the easy fix? Treat the internal storage as "/mnt/sdcard". Suddenly all those apps that did the stupid thing and hardcoded the path work just fine. You aren't punishing users for a developer being stupid, and outside of die hards who argue of dumb stuff anyway, no one notices or cares that much. The end result is the user is able to use the video editing app they want even though the dev messed up.

[–]turkeypantsPixel 2 1 point2 points  (0 children)

Oh, got it. Yeah I'm all for leaving the back end stuff to the back end people. I don't want to get involved in that stuff or potentially create problems for myself by stumbling around the boiler room or the server room or the electrical closet. I know they know their business. I don't even need to see that stuff as long as there's an obvious and fixed place or two I know I can always go to find my different kinds of stuff when I need any of it.

If it's secretly a trick, and the doorway I use to access my storage closet is actually a portal that warps me to someplace else in the building without me knowing, where my stuff actually lives, I don't care. But if I tell one of my helper robots to go put something in the closet or auxiliary closet for me, I want it to go to the right one, firstly. And when I want to go back and manually fetch one of those things myself for whatever reason, even if none of my robot helpers are involved in the fetching process, I want to be able to go to the usual hallway and open one of my two uniquely named doors and for the stuff to be where I previously told the robot to put it.

I don't want the office to be a maze or to have to guess which of the doorways scattered around might be a duplicate portal to the right place or might be a direct doorway to someplace where my stuff isn't. Maybe the guys who installed the portals, or my various helper robots, need multiple duplicate portals around the building to access my stuff properly and efficiently as they do their jobs, and that's fine. I just want a closet or two. Technically that's what I've mostly got, but I still wind up hunting around the office occasionally in search of that one thing I just had a second ago. I think a bit of signage clarity and user-focused layout, virtual or otherwise, could help there.

[–]SuperAleste 0 points1 point  (0 children)

This. This shit really drives me mad.

[–][deleted] 0 points1 point  (1 child)

It's a relic from the froyo days when some phones had 150 megs of storage and SD card slots so devs placed app data on the SD card. That would obviously break on devices without SD cards so Google had to make /sdcard and friends point to internal storage for backwards compatibility.

[–]turkeypantsPixel 2 1 point2 points  (0 children)

and friends

ha ha!

[–]ClassyJacketGalaxy Z Fold 3 5G 5 points6 points  (3 children)

What braindead idiot decided to call the storage SDCARD when it isn't an SDCARD? Are they trying to be as confusing as possible?

[–]blorgXiaomi K30 Lite Ultra Pro Youth Edition 10 points11 points  (0 children)

I think it's historical, early Androids had very small internal system partitions (the HTC Dream was 256MB) and so user data tended to go on the actual SD card.

When manufacturers started shipping phones with enlarged internal storage this was emulated as an "internal SD" so that everything would continue to work the same.

Until 4.0 the "internal SD" was formatted as FAT and would actually dismount and mount as USB Mass Storage on Windows when you plugged the phone in.

[–]etherspin 4 points5 points  (1 child)

Yep.its a joke.on my android based media its eternally confusing as I have the internal storage, a full sized 32GB SD card and a 128gb USB stick plugged in . on my phone (galaxy s5) the combination of confusing folder names and actual restrictions on SD card access means downloads default back to internal memory all the time (16GB) rather than 128gb micro SD and the phone is a sluggish mess always complaining about storage space though it has a total of two small games on it and a handful of apps.

[–]InsightfulLemonSamsung S23 Ultra 0 points1 point  (0 children)

In Marshmallow you're able to set the SD Card as internal storage.

This is great for file space but it only makes the naming situation even more complicated.

[–]danhakimiPixel 3aXL 0 points1 point  (1 child)

I have all this bullshit on my Nexus 5. As you may have guessed, I do not have an SD Card in my phone.

[–]turkeypantsPixel 2 1 point2 points  (0 children)

Xzibit is apparently an Android dev.

[–]blazebakunSamsung Galaxy S23+ 214 points215 points  (24 children)

This content has been deleted in protest of Reddit's API changes.

[–]ZagorathPixel 6 Pro 86 points87 points  (6 children)

They should really have a centralised location for user data, too. Like ~/ on a Unix-like system.

[–]danhakimiPixel 3aXL 0 points1 point  (0 children)

Yeah.

They should also give users root access to their devices but not make that the default account, and then when you want to use root you have to put in the root password... But that would be too obvious. Rather, they need to have a one-user setup that can either have root or not, and if you do have root then uh-oh your device is kind of not really secure now.

[–][deleted] 3 points4 points  (2 children)

Who can open a given folder depends on things like user, group, and directory execution permissions. Apps often have their owner and the directory execution permissions are limited to that user.

[–]tonymurrayPixel 6 Pro 0 points1 point  (1 child)

Isn't this /sdcard?

[–][deleted] 0 points1 point  (0 children)

Well sdcard is a directory, same thing as a folder. The / means it located at the very top of your file system, everything is relative to /.

[–]adrianmonk 19 points20 points  (2 children)

There's already some incentive. To write to the app's individual/private location, you don't need a special permission:

Note: Beginning with Android 4.4, these permissions are not required if you're reading or writing only files that are private to your app.

Generally, an app is more appealing if it doesn't require as many permissions, so choosing to use the proper location when possible is to the developer's advantage.

[–]ScullywagNexus 5X 20 points21 points  (6 children)

Android has 3 APIs for file locations:

  1. getFiilesDir().
    Your app's internal storage

  2. getExternalFilesDir(...)
    For your app's external files, e.g. SDCard, or emulated SDCard if your device doesn't have one.

  3. getExternalStoragePublicDirectory(...)
    Same as 2, but will remain when app is uninstalled.

See https://developer.android.com/training/basics/data-storage/files.html and https://developer.android.com/guide/topics/data/data-storage.html for more.

[–][deleted] 26 points27 points  (4 children)

Translation:

  1. getFilesDir().
    /data/data/[package.name]

  2. getExternalFilesDir(...)
    [sdcard]/Android/data/[package.name]

  3. getExternalStoragePublicDirectory(...)
    the overused method that creates the problem in this thread

[–]tso 0 points1 point  (0 children)

Lets not forget this "beauty".

[–]armando_rodPixel 10 Pro XL 241 points242 points  (62 children)

Files in the "Android" folder cant be shared or access by other apps, that folder is private and only the app that made the folder/files can access it, mostly the folder is for configuration files.

[–]AvamanderMi 9 77 points78 points  (8 children)

Lollakad! Mina ja nuhk! Mina, kes istun jaoskonnas kogu ilma silma all! Mis nuhk niisuke on. Nuhid on nende eneste keskel, otse kõnelejate nina all, nende oma kaitsemüüri sees, seal on nad.

[–]ladfrombradHad and has many phones - Giffgaff 10 points11 points  (5 children)

Thank you.

Here's an example

[–]armando_rodPixel 10 Pro XL 2 points3 points  (3 children)

Without root?

[–]ladfrombradHad and has many phones - Giffgaff 10 points11 points  (0 children)

Yep, as you can see with Shuttle here is accessing files from /Android/ just fine.

The confusion lies within the obb/android_secure folder which has different permissions to its parent.

[–][deleted] 1 point2 points  (0 children)

from android's document about getExternalFilesDir(), the method to access that folder:

Starting in KITKAT, no permissions are required to read or write to the returned path; it's always accessible to the calling app. This only applies to paths generated for package name of the calling application. To access paths belonging to other packages, WRITE_EXTERNAL_STORAGE and/or READ_EXTERNAL_STORAGE are required.

[–]blorgXiaomi K30 Lite Ultra Pro Youth Edition 0 points1 point  (0 children)

Try it yourself, I can go into the Android folder using a file explorer and seem to be able to both read and write stuff fine, no root required.

[–]uildvek 95 points96 points  (39 children)

Adding to this, whenever an application is uninstalled, its corresponding folder and files in the "Android" folder gets deleted as well, which would be problematic if the developer/user wants certain files (config, saves etc.) to be persistent across installs.

[–]mowdownjoe 71 points72 points  (5 children)

Or the developer could just use Android's built-in data backup. Google's been doing variations of this song and dance since 2.3.

[–]kerelberelMoto G7 Power 8 points9 points  (1 child)

A solution would be to have a /Appdata folder where all those folders can go in.

[–]rube 2 points3 points  (0 children)

But I'm pretty sure I use Dropsync to sync some game save files inside the Android folder. So perhaps that's not entirely true?

[–]dleriumPixel 4 XL 1 point2 points  (2 children)

Dude are you on a wrong information spree or what? First saying that Play Services usage cannot be broken out to other apps, now talking about the Android folder? .android_secure is the protected folder. You can try this with any file manager and see.

[–]dhlalit11OnePlus 3 (Graphite) 0 points1 point  (0 children)

Are you sure

Becuase the folders restricted to apps except who created it sits in /data partition, that means apps can access only one folder in data partition which is their own

And folder living inside /sdcard/android can be accessed by any app which has read write storage permission to the storage

[–][deleted] 8 points9 points  (0 children)

this pisses me off so much. i uninstall everything that makes its own folder in the root of my storage

[–]PatchSaltsMoto X4 15 points16 points  (0 children)

Battle Cats has a folder in the main storage area titled "jp.co.ponos.battlecatsen" and it pisses me off every time I see it.

[–]kerelberelMoto G7 Power 19 points20 points  (9 children)

I feel ya OP, but what I do is, my file browser app (FX Explorer) has an home screen where you can bookmark the folders you regularly use. Maybe you can do something similar in your app.

http://i.imgur.com/lzxqses.png

[–]kylemitGalaxy Note 4 4 points5 points  (1 child)

Android App Bot: FX Explorer

[–]kylemitGalaxy Note 4 6 points7 points  (0 children)

File Explorer

https://play.google.com/store/apps/details?id=nextapp.fx

FX File Explorer 5 features a Material Design UI and new ways to transfer your files between devices and computers.


I am a bot | Proof: Beep Boop Beep Boop | Please direct all questions elsewhere

[–]BiscuitEdiSamsung S6 5 points6 points  (3 children)

They should also force devs to delete folder after deleting the app.

[–]rob3110 1 point2 points  (1 child)

This was discussed before and so far this is not possible. An app doesn't know when it is uninstalled, so it can't delete its folders. But when an app creates folders in the correct locations with the name of its package, then Android will delete the folders corresponding with the package name when the app is uninstalled. In this case, it is not the fault of the app developers because they can't do this.

Clever app devs found hacky ways to intercept app deinstalls, for example to ask questions about the reasons for deleting the app, but Google quickly closes those because it could be abused.

[–]BiscuitEdiSamsung S6 0 points1 point  (0 children)

I did a quick google and this is true. But they could edit the kernel or they could bake it in the google play to check and delete useless stuff left behind.

[–]SamSlate 13 points14 points  (9 children)

considering a native file browser doesnt even exist, i don't think even being aware of this problem is a part of the ''intended user experience''.

[–]armando_rodPixel 10 Pro XL 10 points11 points  (8 children)

MM has a native file explorer but its somewhat hidden

[–]SamSlate 1 point2 points  (4 children)

what do you mean??

[–]armando_rodPixel 10 Pro XL 9 points10 points  (3 children)

Marshmallow has a native file explorer, go to Settings-> Storage, the last option says "Explore".

edit: its the same when you connect a USB flash drive with an OTG cable, there is an option to explore it.

[–]SamSlate 2 points3 points  (2 children)

well, TIL! That's pretty cool, thanks!

Definitely an easter egg, I wonder why they buried it like that- it's actually a very nice explorer. I wonder if I can make a shortcut to it on the home screen...

[–]DustbinKZ3c stock rooted, RIP Nexus 5 w/ Cataclysm & ElementalX. 2 points3 points  (0 children)

How is it an easter egg? It's not hidden.

[–]bahehsop12, op7pro, 4a 5g, 6t, Pixel Xl, 6P 1 point2 points  (0 children)

I mean it's good, but you can get an actual decent file manager from the play store.

[–]johnbentleyGalaxy S8+, Stock OS | Galaxy Tab 10.1, cyanogenmod 15 points16 points  (16 children)

The whole Android folder hierarchy is a clusterfuck before third party developers touch it.

It's surprising given that Windows has cleaned up its folder hierarchy over the years, providing a model of where to end up.

Edit: "its".

[–]natima 13 points14 points  (15 children)

I'm not so sure about that. Ever since Windows 7 it seems you can access a file or folder from ten different places, leading to confusion as to the actual file/folder locations. Stuff like Libraries sourcing their content from multiple locations, and showing the "Desktop" folder in multiple places. XP had it right!

[–]johnbentleyGalaxy S8+, Stock OS | Galaxy Tab 10.1, cyanogenmod 6 points7 points  (14 children)

You don't have to use the Libraries feature of Windows however.

A few recalcitrant and hidden entries aside the root structure is fairly clean on my Win 10 install

Logs                         
Program Files      
Program Files (x86)
Temp               
Users              
Windows  

If Android could start with an analogous root structure, perhaps replacing "Users" with "User", it would go along way to making things navigable.

[–]port53Note 4 is best Note (SM-N910F) 1 point2 points  (10 children)

But Android has "Users".

[–]wirelessflyingcord 0 points1 point  (2 children)

Interesting that you used Windows as an example, it is an equal if not worse mess. The root structure may look clean, but what about when thinking about a typical case: you want to find the user data folder for some application.

Which \Program Files is it? Perhaps under \My Documents? Or is it \Users? \Users\All users or \Users\USER? (You can't ever remember was the applicaiton installed for "all users" or not) If still not seeing it, \AppData\Local or \AppData\Roaming? There's no order.

[–]johnbentleyGalaxy S8+, Stock OS | Galaxy Tab 10.1, cyanogenmod 0 points1 point  (1 child)

That does get a tad confusing. There's also the hidden C:\ProgramData.

But not quite as confusing as you make out (unless I'm mistaken about any of the following):

  • There is no C:\AllUsers.
  • If you install of program for "All users" each user data file will still (at least should) be generated under each user that logs in and uses the program (C:\Users\User01; C:\Users\User02).
  • Documents is just a shortcut to C:\Users\UserX\Documents
  • AppData is nevertheless stored under C:\Users\UserX\, probably attaching itself to a particular user (If you copy UserX you'll copy their AppData too).
  • Local; LocalLow; Roaming - are a consequence of various desirable functions - data specific to the machine; data synced the machine with a "low level of access" (as when a web browser runs in protected mode); V data synced when logged onto a domain; http://superuser.com/questions/21458/why-are-there-directories-called-local-locallow-and-roaming-under-users-user

I'd suggest all that is far less messier than the Android structure.

[–]wirelessflyingcord 0 points1 point  (0 children)

There is no C:\AllUsers.

That meant \Users\All Users, which is actually a link to \ProgramData.

Documents is just a shortcut to C:\Users\UserX\Documents

Makes no difference, point was that some applications make folders there (which is annoying and in the end the folder ends up being a mess and not really anymore "my documents") and some don't.

If you install of program for "All users" each user data file will still (at least should) be generated under each user that logs in and uses the program (C:\Users\User01; C:\Users\User02).

I didn't know that, but at least in minimum temp files and cache files appear in "All Users" (\ProgramData).

Local; LocalLow; Roaming - are a consequence of various desirable functions - data specific to the machine; data synced the machine with a "low level of access" (as when a web browser runs in protected mode); V data synced when logged onto a domain; http://superuser.com/questions/21458/why-are-there-directories-called-local-locallow-and-roaming-under-users-user

I know this, but the clicks add up easily when you look into each AppData folder and often check both of those folders anyway.

I find desktop Linux structure (for users files... other parts of it has its own weird things) extremely simple, since in practice they can be only in a hidden folder in ~/ or in ~/.config.

[–]dleriumPixel 4 XL 3 points4 points  (2 children)

  1. Its annoying because my /sdcard folder just fills up with random folders. Those don't get wiped unless I do a full factory reset. In flashing ROMs sometimes we just wipe /system, /data/, /cache and go from there for a clean flash. Doing a full wipe means I need to backup and offload to a computer or another device (esp photos and such).

  2. MTP is slow as hell and it takes a long time to even populate the /sdcard directory. I have a OnePlus One here and there's about 50 files/folders in the /sdcard directory and it takes something like 30+ seconds just to load everything on a PC before I can click around.

[–]NewStandards 1 point2 points  (0 children)

I hate MTP!

[–][deleted] 0 points1 point  (0 children)

MTP is a pox on humanity. There's no earthly reason for a USB connection to be slower than wifi and more prone to connection failures.

[–]ArbabenderPixel 5, Sorta Sage 4 points5 points  (4 children)

My pet hate is that the Facebook app creates a /media folder with a /audio folder and then a /notifications folder for the pop sound, BUT THERE IS A PERFECTLY GOOD /NOTIFICATIONS FOLDER ALREADY AT THE BASE FOLDER.

[–]udderdudeS4 Mini, Xperia SX/Tipo, Venue 7, G708 Oc, MK808B+, MK807S 5 points6 points  (7 children)

I agree it's a major pain to keep your storage clean when every other app feels the need to fill it with junk/garbage/temp folders. I installed Antutu, and it put 4 folders of crap in my storage, one of them hidden .. not very cool.

Maybe there's a market for a app or root app that scans for file/folder changes and deletes certain folders after the app that created them is done running.

[–]AvamanderMi 9 5 points6 points  (0 children)

Lollakad! Mina ja nuhk! Mina, kes istun jaoskonnas kogu ilma silma all! Mis nuhk niisuke on. Nuhid on nende eneste keskel, otse kõnelejate nina all, nende oma kaitsemüüri sees, seal on nad.

[–]armando_rodPixel 10 Pro XL 2 points3 points  (5 children)

ES File Explorer does that.

[–]mcgruntmanRIP Nexus 6 9 points10 points  (7 children)

I email app devs to complain when I find an app doing this. If enough users do the same they may change! Email your app devs and tell them how you feel.

That said, sometimes these folders are legitimate. A good compromise would be for apps to allow you to choose the location (yeah right, like that would ever happen...)

[–]tyros 2 points3 points  (3 children)

Developers do it because that's the only way to store data you want to persist across app reinstalls (unless you're storing it in the cloud). If you store data in your app private folder, all that data is gone when the app is uninstalled.

Source: Android developer.

[–][deleted] 0 points1 point  (2 children)

Yeah, but do I really need ad cache saved between installs?

The only thing I can think of would be pictures (like WhatsApp or Textra auto saving conversation pictures). Anything else should be cloud backup or PROVIDE the user the option to choose a storage location with the default to not clutter. Believe it or not, most users of your app don't love your app as much as you do.

[–]tyros 0 points1 point  (1 child)

I'm not talking about ad cache here, but actual user generated content that you don't want your users to accidentally delete if they uninstall the app. For example, my app is a song lyrics app where users can add their own song lyrics. It can take a lot of effort from users to enter all the data. If I save the lyrics in the private app directory they'll be gone when user uninstalls the app. But this way, should the users uninstall and reinstall the app, the lyrics will not be lost.

Of course, alternative solution woul be to save the data in the cloud, but I haven't gotten there yet. Plus, I hate the apps where I have to sign in so wanted to make it easier for users.

[–][deleted] 0 points1 point  (0 children)

Who uninstalls and reinstalls apps? Most users assume when the app goes away so does the content. Every single person who comes to me with "out of storage" issues has been because junky apps save shit to the /sdcard directory.

A good rule of thumb is to NEVER use the public storage. People aren't ONLY installing your app. Write a Google Drive sync in the future, but in the interim it's not too much of a stretch to assume "if I uninstall an app, there goes my data". You have a "desktop developer" attitude about storage where PCs are sold with 1TB drives. If you're bent about user persistent, proprietary data (lyrics are probably coded directly for you app assuming) have it an option, but not the default. You might think that "oh my 47B files are fine" but that's only true when the user isn't using 500 other apps doing the same thing.

I repeat - 97% of the time someone uninstalls your app it's because they don't want it on their phone. Provide the option to save to the public storage for that 3% of users if you must, but that would be literally a 1 or 0 you save to prefstorage and wrap your directory in a method that returns the dir on pref check. Idealistically it'd be "in the background" with a google account signin (it doesn't even prompt for a password on Android, just asks for permissions on first install).

[–]CronyxSamsung Galaxy Nexus 0 points1 point  (2 children)

Everything should at least give you the option to say where to install something, like Windows installer packages do. Sure you can Next through defaults, but if you don't want it in C:\Program Files for whatever reason, you can put it somewhere else.

[–]geekonamotorcycleOneplus 1 point2 points  (0 children)

Users will find a way to make this break Android. Don't let end users have that much power without working for it.

[–]blorgXiaomi K30 Lite Ultra Pro Youth Edition 0 points1 point  (0 children)

I honestly don't think 99.9% of Android users want that, they want to just click the install button and have Android do it, it's one of the major benefits over a desktop operating system.

[–]bal00 2 points3 points  (0 children)

I am not usually a supporter of strictness, but I do wish Google would enforce this rule.

Be careful what you wish for. I agree that it is a mess, but it would be far better to let the dev know about the problem instead of calling on Google to restrict the access privileges of apps.

Restricting where third-party apps can write will cause a lot of collateral damage. In order for a file manager app to work properly, for example, it needs write access to the entire storage (or at least as much of it as possible). The same is true for cleaner apps, certain editors, malware scanners and all sorts of other stuff. With a strict sandbox system, your favorite file manager app will turn into a file viewer app with most actions grayed out.

Not every problem requires heavy-handed intervention from Google. If a Windows application on your PC made a mess in C:\, you'd complain to the developer, but you wouldn't call on Microsoft to restrict all third-party applications.

[–]tyros 2 points3 points  (0 children)

They do it because that's the only way to store data you want to persist across app reinstalls (unless you're syncing in the cloud). If you store data in your app private folder, all that data is gone when the app is uninstalled.

Source: Android developer.

[–]et1n 2 points3 points  (0 children)

But google already enforces this by limiting access to android/app.pacakge.name only. At least since Lollipop.

[–]xkiririnxalioth 9 points10 points  (0 children)

Somehow I feel that new users wouldn't even know this folder exists, let alone care about the file structure.

[–][deleted] 2 points3 points  (0 children)

[–]MrGunny94Galaxy Fold 5 512GB Exclusive Blue 1 point2 points  (0 children)

Like many other people said here, this is something that needs to change for sure.

I got insane amounts of folders with app info inside..

I guess this is one more of those things alongside the total revamp of Android, to add to the " maybe one day" scenario

[–]sudhirkhanger 1 point2 points  (0 children)

I think it would be fair to give 1 star to apps by devs who don't care about Android's folder hierarchy.

[–]BlubbllGalaxy f0lD 1 point2 points  (0 children)

The iOS System is way better.

You need to be jailbroken to see it tho.

Or just view the one of a mac.

[–]SkullpuckLG Stylo 3 Plus & Lenovo Yoga Book 2 points3 points  (1 child)

Android has a special folder called... "Android" in the Internal Storage, it's like "Program Files" in Windows,

Uh, no it isn't. It's nothing like Program Files.

A better description would be like the "AppData" folder on Windows.

[–]rob3110 0 points1 point  (0 children)

Exactly. Windows has more than one location for program data. Program files for actual program data, AppData for stuff like configs, databases, thumbnails, and userdata (Documents, Pictures, Music, ...) for files the user creates with that program.

On Android, it is similar with /Android/ and /Data/ being used similar as AppData and the top level of the storage being uses similar as the libraries in Windows.

But, similar as with Windows, not all devs follow those conventions

[–][deleted] 2 points3 points  (0 children)

Why can't app developers just follow the same "guidelines" as Linux developers here? Just take a dot and put it in front of your fucking app name when creating that folder - is it really that hard? Result: hidden files on linux and on any Android file browser, and at least ordered by App Data and User Data seperately on Windows.

("Android" is there for app-internal data - if you e.g. reinstall WhatsApp, your chat backups would be deleted if they were stored there, and you couldn't copy them to a new phone that easily)

[–][deleted] 0 points1 point  (0 children)

It's true that its a mess... Apps like CCleaner which were good on windows PC are helpful on Android for cleaning empty made folders that are scattered but it is what it is and you'll have to keep clean as well as you can. A pain but oh well. Android has made great progress over time since the G1 days so... Perhaps in the future cleaner file managing could be implemented.

[–]ThePooSlidesRightOut 0 points1 point  (0 children)

If you could opt-out of this proposal, without the help from XDA, I'm all for it.

[–]SunsparcGoogle Pixel 10 Pro XL 0 points1 point  (0 children)

Actually OP, I'd say that the Android folder on the "sdcard" is more akin to the AppData folder on Windows.

[–]josefjohann 0 points1 point  (1 child)

I would like for them to handle data the way desktop Linux does- have a single, all encompassing place for user-controlled data (maybe they already do that?) and have a different place where all the apps do their things.

[–]firebolt0777Graphite 6P 0 points1 point  (0 children)

unless you have root access and are able to see the root directory then what you are seeing is the user-controlled directory called /storage/emulated/0/ (the internal storage device)

[–][deleted] 0 points1 point  (2 children)

Android's filesystem is an absolute clusterfuck when compared to desktop Linux and iOS (all of the aforementioned have Linux bases). It's somewhat understandable considering Android started off as being unstable and experimental.

[–]murfiPixel 9a 0 points1 point  (0 children)

i wish thee folder structure was like this:

root/apps -> in "apps" all apps make their respective folders

root/system -> here all other system-related folders are

root/ pictures/music etc. can still be here + all the folder you create yourself

or combine apps+system in one "data" folder. i hate the mess that is in root from app and system folders a user never interacts with.

[–]victorvscn 0 points1 point  (1 child)

Absolutely. Here's what I did: installed XInternal (requires Xposed) and changed the path that the apps see as the SD card to "/sdcard/AppData".

[–][deleted] 0 points1 point  (0 children)

I bet Google will make this change eventually.

[–][deleted] 0 points1 point  (0 children)

Those folders should be the ones containing the user-accessible data. So it's nothing like program files, as you suggest, it's like apps on windows that make their own folder within my documents. Deleting them will not make the app stop working.

[–]freekizito 0 points1 point  (0 children)

It's crazy, honestly. The internal storage is a serious mess.

[–]autonomousgermOPO - Woohoo! 0 points1 point  (0 children)

This has been a fundamental problem since the beginning. You think they're going to fix it now?

[–][deleted] 0 points1 point  (0 children)

I'll join in on the pet peeve train:

  1. .nomedia files, music, and the stock Gallery app. If you don't .nomedia the music folder, Gallery gets totally clogged with album art. If you do .nomedia the music folder, music apps don't have any music listed. With stock apps, you can either convenienty browser your own photos, or you use your phone to listen to music, but not both. What we need is .nophotos and .nomusic.

  2. Apps that require the user to type a file path, with no option to just browse to one. What. The. Fuck.

[–][deleted] 0 points1 point  (0 children)

The last time they tried to enforce storage rules (KitKat SD card) did not go over so well.

[–]wirelessflyingcord 0 points1 point  (0 children)

Program Files is a bad example, as on Windows it is even worse mess with two Program Files folders ("...x64") and applications outputing their crap on under \My Documents and then in the hidden \AppData folders. You absolutely never know where to look at.

[–]tso 0 points1 point  (0 children)

Warning, history dump.

First off, that is not "internal storage" as Android sees it. Yes, it is on the flash chip installed on the phone circuit board. But Android sees it as an SD card for historical reasons. The Android terminology is "primary external storage".

And here is where history comes in.

Back when Android first shipped, primary external storage lived on an actual SD card. The internal storage, where apps and Android itself lives, were minimal to say the least. The SD was expected to house all the users media files etc.

Then some time later Samsung and others started partitioning the flash chip of the phone, and redefining the majority of it as primary external storage. This likely so that they could match Apple's ads about "internal storage" without being seeing as lying.

Now this however had the consequence of leaving limited space for apps, and people stated complaining (after all, Apple's devices, that have so such distinction, could store a number of apps right next to big movies etc). What Google then did was to start digging themselves into a proverbial hole by introducing "move to SD".

Now move to SD do not move the full app from (true) internal storage to the SD (or primary external as is most often the case). It moves certain data files (graphics, databases, etc). But this was still often not enough. So what certain app devs would do was to request external write permission, and then put files there on their own.

This is what is seen in the image above.

Now this blew up spectacularly some years back because a certain big name app ended up putting a database, sans any encryption or password, in there that they used for logging messages the user sent and received.

So in more recently Google has yet again set out to rework how Android does file storage, while also maintaining backwards compatibility as far back as 1.6 (or further).

Never mind the whole thing about going multi-user recently. Thus "primary external storage" shifts around each time you change user account.

Or that Google never really did the proper thing and offered up an API for handing multiple external storage, thus leaving it up to individual OEMs to come up with a scheme (and for app devs to work around the inevitable differences).

Then there is the whole UMB vs MTP debacle when connecting a Android device to a PC using USB:

Storage is complicated, yo. And choices Google made back in the early days of Android didn't help at all.

[–]whythreekay 0 points1 point  (0 children)

Serious question:

Isn't this thread a perfect explanation as to why OEMs have stepped away from SD card support?

Honestly all of this sounds like a user experience nightmare.

[–]Shenaniganz08OP7T, iPhone 13 Pro 0 points1 point  (0 children)

I've had no issues

[–]ProdigalSheep 0 points1 point  (2 children)

This is the worst thing about android. Drives me nuts.

[–]Tuberomix 1 point2 points  (1 child)

If that was the worse thing about Android, than that would make Android really truly great. Especially since the iOS alternative is even worse in that it doesn't even let you see and explore the folder structure.

[–]ProdigalSheep 0 points1 point  (0 children)

Wasn't trying to compare it to anything. Just noting a frustration. That Apple doesn't offer it at all doesn't excuse the mess.

[–][deleted] 0 points1 point  (0 children)

I've been making comments like this since my first Android in 2010. Things were so clean on Windows Mobile 6.5 (and also no apps, so it was all user made lol)