Maaz Zindani

Loading the index…

↑↓ move↵ openesc close4072 pages
Flutter and app store releases

Play Console rejects the native debug symbols zip because of __MACOSX

ErrorThe native debug symbols contain an invalid directory __MACOSX

Short answer

Google Play expects the root of the debug symbols zip to contain only ABI folders such as arm64-v8a and x86_64. A zip made with the macOS Finder adds a __MACOSX folder, and a zip with an extra lib level has the wrong layout. Zip the ABI folders from the terminal, or let the Android Gradle Plugin build the file.

  • Applies to Flutter 3.x, Android Gradle Plugin 8.x, Play Console
  • Updated
  • By Maaz Zindani, Senior Software Engineer

Fix it fast

  1. 1Find out which cause you have

    List the top level of the zip you are about to upload. It must show only ABI folders.

    unzip -l symbols.zip | head -n 20
  2. 2Match what you see, then jump to its fix

    1. 1unzip -l shows entries starting with __MACOSX/The zip was made with the macOS Finder and contains __MACOSXFix
    2. 2unzip -l shows lib/arm64-v8a/... or a project folder name at the topThe ABI folders are not at the root of the zipFix
    3. 3You build an app bundle with Android Gradle Plugin 4.1 or newerYou are zipping by hand when the Gradle plugin can build the fileFix

What does the error look like?

  • The native debug symbols contain an invalid directory __MACOSX

Cause 1 of 3

The zip was made with the macOS Finder and contains __MACOSX

1Check

The __MACOSX folder is created by macOS when it compresses a folder. It is not part of your Flutter or Android project, and deleting the macos folder of the project does not remove it.

unzip -l symbols.zip | grep MACOSX

2Fix

Build the archive from a terminal, from inside the folder that holds the ABI directories, as Play's own instructions describe.

cd path/to/obj
zip -r symbols.zip .

3Verify

List the new archive again: no __MACOSX entries, and the ABI folders at the top.

unzip -l symbols.zip | head -n 20

Confirmed by support.google.com

Did this fix it?

Cause 2 of 3

The ABI folders are not at the root of the zip

1Check

Play requires the root of the archive to contain the ABI folders armeabi-v7a, arm64-v8a, x86 and x86_64, each with its unstripped .so files.

unzip -l symbols.zip | awk '{print $4}' | cut -d/ -f1 | sort -u

2Fix

Run zip from inside the directory that directly holds the ABI folders, so no parent folder is added.

cd path/to/folder-with-abi-dirs
zip -r symbols.zip .

3Verify

The top-level names printed by the check are ABI names only.

unzip -l symbols.zip | awk '{print $4}' | cut -d/ -f1 | sort -u

Confirmed by support.google.com

Did this fix it?

Cause 3 of 3

You are zipping by hand when the Gradle plugin can build the file

1Check

With an app bundle and AGP 4.1+, one Gradle setting includes the symbols in the bundle automatically, and no manual upload is needed.

grep -rn "debugSymbolLevel" android

2Fix

Set the symbol level in the app module's Gradle file and build the bundle again. If the file is over 800 MB, use SYMBOL_TABLE instead of FULL.

android {
    defaultConfig {
        ndk {
            debugSymbolLevel = 'FULL'
        }
    }
}

3Verify

Build the bundle again and upload it; no separate symbols file is needed.

flutter build appbundle

Confirmed by support.google.com

Did this fix it?

How do I stop it coming back?

  • Prefer the Gradle setting over hand-made zips, so there is no archive to get wrong.
  • If you must zip by hand, always do it from the terminal and check the listing before upload.
  • Upload symbols for every release, because Play deobfuscates only crashes that happen after the upload.

Sources

How was this page made?

I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.

Which stack is behind this page?

Projects of mine built on the same technologies:

Related fixes

Mobile apps

Google Play says the app does not support 16 KB memory pages

check_elf_alignment.sh reports UNALIGNED for a library under lib/arm64-v8a

Google Play requires apps that target Android 15 or higher and ship native .so libraries to run on devices with 16 KB memory pages; from 1 February 2027 it will block updates that do not.

5 causes, each with a fix

Next step

Want this handled for good?

I look after servers, apps and releases end to end. Tell me what keeps breaking.