Minecraft – How to un-tame a wolf through NBT

minecraft-commandsminecraft-java-edition

On any given server, the need to untame a wolf (without killing it) for whatever reason arises eventually.

However, upon attempting to do this on my own test server with the below command, nothing happened. The wolf was still tame to me, and would refuse to let go.

/entitydata @e[type=Wolf,r=5] {Owner:,OwnerUUID:}

What am I missing or doing wrong here?

Best Answer

In order for a change in owner to be considered, the OwnerUUID tag must not have an empty value. However, providing it a correctly-formatted UUID will cause it to be tamed to whoever has that UUID (even if nonexistent). If you provide it with an invalid format, it will instead become wild as though it were never tamed:

/entitydata @e[type=Wolf,r=5] {OwnerUUID:"blah"}

The Owner tag is deprecated, and is ignored if OwnerUUID is specified.