Android App: Stripping GPS Exif when uploaded from Gallery

I have a specific use case in which I need to upload images with the GPS tags. The photos are taken from an Android tablet.

If I use the Nextcloud app to upload the files from “Camera” without placing them into a Gallery, first, the GPS meta remains intact.

If I add the photo into a Gallery, then upload from that Gallery (using + > Upload Content From Other Apps > my-gallery > select photos), then the GPS exif is gone.

The same thing happens if I “Share” the image to Nextcloud.

Anybody have any experience with this? The file name stays the same, as does the size of the file. Exif data for images is inside the actual image file, itself, so I have no idea why that is happening.

Again, I want to reiterate, if I + > Upload Content From Other Apps > “Select images from default “Recent” tab”" then the images will upload to Nextcloud with the Exif in place.

If I, instead + > Upload Content From Other Apps > Gallery > Select images, then the Exif is stripped.

If I go into the Android Gallery itself and look at the images, I can see that the Exif data is still there.

Sounds like a bug/feature of your gallery program, which is stripping the data when it is sharing it.