Marked as helpful by the asker
Hannah is right about the cause. Concretely, with Expo:
import * as FileSystem from "expo-file-system";
import { decode } from "base64-arraybuffer";
const base64 = await FileSystem.readAsStringAsync(image.uri, { encoding: "base64" });
await supabase.storage
.from("photos")
.upload(path, decode(base64), { contentType: "image/jpeg" });(Newer expo-file-system versions also let you read a File as bytes directly, which skips the base64 step.) Resize before upload with expo-image-manipulator, phone photos are 3–5MB and you don't want those in a list view.
ArrayBuffer version works. Resizing to 1200px too, uploads are way faster now adebayo_t · edited