Maaz Zindani

Loading the index…

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

adb prints 'server version doesn't match this client; killing...'

Erroradb server version (40) doesn't match this client (41); killing...

Short answer

adb runs a background server, and every adb command is a client. When the client finds a server of a different version, it kills that server and starts its own. Two different adb copies on the machine cause it. Find them, then use one platform-tools install everywhere.

  • Applies to Android SDK Platform-Tools (latest), macOS 26, Ubuntu 24.04
  • Updated
  • By Maaz Zindani, Senior Software Engineer

Fix it fast

  1. 1Find out which cause you have

    List every adb binary on the PATH and print the version of each. More than one path means two adb builds share the server.

    which -a adb
    adb version
  2. 2Match what you see, then jump to its fix

    1. 1which -a adb prints more than one pathTwo copies of adb are installed, for example one from a package manager and one from the SDKFix
    2. 2the message comes back every time you switch between Android Studio and a terminal or another toolTwo tools take turns replacing each other's serverFix
    3. 3adb version shows an older number than the SDK Manager offersThe Platform-Tools package is oldFix

What does the error look like?

  • adb server version (40) doesn't match this client (41); killing...
  • adb server version doesn't match this client; killing...

Cause 1 of 3

Two copies of adb are installed, for example one from a package manager and one from the SDK

1Check

Compare the versions of each binary by running each path with version.

which -a adb
"$ANDROID_HOME/platform-tools/adb" version

2Fix

Keep one copy. Android's own guidance is to take the platform-tools from the SDK Manager, so remove the other one and put the SDK folder first on the PATH.

export ANDROID_HOME="$HOME/Library/Android/sdk"   # use your own SDK path
export PATH="$ANDROID_HOME/platform-tools:$PATH"

3Verify

Only one adb path is printed.

which -a adb

Confirmed by developer.android.com

Did this fix it?

Cause 2 of 3

Two tools take turns replacing each other's server

1Check

The adb client compares its own server version with the running server. When they differ it prints this message, kills the old server and starts a new one, as the adb source shows. A tool that bundles its own adb will do this to yours.

which -a adb

2Fix

Point every tool at the same adb binary, or stop the server and let one tool start it.

adb kill-server
adb start-server

3Verify

Switch between the tools and check that the message stays away.

adb devices

Confirmed by android.googlesource.com

Did this fix it?

Cause 3 of 3

The Platform-Tools package is old

1Check

Google says adb and fastboot are backward compatible, so you should only need the latest SDK Platform-Tools.

adb version

2Fix

Update Platform-Tools in Android Studio's SDK Manager, or with the sdkmanager tool, then restart the server.

adb kill-server
adb start-server

3Verify

The new version number shows.

adb version

Confirmed by developer.android.com

Did this fix it?

How do I stop it coming back?

  • Install platform-tools once, from the SDK Manager, and keep it on the PATH.
  • Do not install a second adb with a package manager when Android Studio is on the machine.
  • Update Platform-Tools when you update Android Studio.

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

adb tcpip 5555 fails because no device is found

adb: more than one device/emulator

adb tcpip only works while the device is attached and listed by adb, because it tells the phone to start listening on port 5555.

4 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.