I have a Minecraft server which allows Bedrock clients, I would like to make one of our players who has a space in their Gamertag an operator.

We tried op "user name", however this throws exceptions harder than my lawyer ;P

Any ideas? :)

4 Answers 4


The quotation mark method seems like it would work, but it doesn't in /op. However there are still other methods that work. As the other answer mentions, you will be able to get a player UUID from that person in the chat.

But what if the player hasn't chatted recently?

If your player hasn't chatted recently, you won't see their username in chat and won't be able to get a UUID. Sure, you could just ask them to send a chat message, but that will get tricky when you're trying to deop a person, because they can resist you by simply not sending any chat messages.

But, there is yet another method that is the most elegant:

Specified the player to be grant op to. In Java Edition, must be a collection of game profiles (player profiles), which can be a player name (must be a real one if the server is in online mode), or a player-type target selector.

A target selector (@p, @r, @a, @e) can also be used to select a player. And target selectors have a name argument to select targets by name, and unlike /op directly? It allows " syntax.

This is the command to use:

op @a[name="a name with spaces and \"quotation marks\""]
  • 1
    Nice one, I like the bit about the double-quoted string too; cheers!
    – Sean Airey
    May 19, 2021 at 0:30
  • 1
    I imagine this still suffers from the UUID spoofing trick? Seeing as it will lookup the UUID from the name? I assume... shrug
    – Sean Airey
    May 19, 2021 at 0:36
  • @SeanAirey I'd doubt the second method would be
    – Penguin
    May 19, 2021 at 22:18

If you hover over the user's name in chat, you'll see their UUID, e.g. 584fb77d-5c02-468b-a5ba-4d62ce8eabe2. You can use this in the /op command instead of a username: /op 584fb77d-5c02-468b-a5ba-4d62ce8eabe2

  • 4
    SECURITY ALERT: Assuming this is a server running GeyserMC/Floodgate, you open yourself to potentially OP-ing (you can't OP one without OP-ing the other) the owner of the UUID (if one exists); do a lookup of the UUID first, though the chances of it happening might be miniscule, it is still a security risk.
    – aytimothy
    May 18, 2021 at 23:09
  • 2
    @aytimothy I don't understand that response. To clarify, I am asking whether the security risk you just pointed out is present in my answer also.
    – One 2 Many
    May 19, 2021 at 2:51
  • 1
    @aytimothy I'm confused. Isn't OP-ing the owner of the UUID the exact goal?
    – Polygnome
    May 19, 2021 at 16:26
  • 2
    @Polygnome Bedrock players will be assigned a random UUID as they don't have a Java one, which may be the same as an actual Java player's UUID. It's so unlikely that I'd say it would never happen (the person would have to join your server, even if they manage to match the UUID), but I guess the chance is still there.
    – 4P5
    May 19, 2021 at 17:48
  • 3
    @aytimothy as long as the UUID generation code is actually random, you're more likely to have cosmic rays give someone OP than for a UUID collision to happen.
    – mbrig
    May 19, 2021 at 22:53

You could try adding to your ops.json:

    "uuid": "61c1bca3-2d8a-4756-a4fb-26fe22f3b000",
    "name": "Damemon",
    "level": 4,
    "bypassesPlayerLimit": false

Replace 61c1bca3-2d8a-4756-a4fb-26fe22f3b000 (UUID) and Damemon (username) with your friend's Floodgate UUID and name. The level and bypassesPlayerLimit can be left as-is.


Put the first letter in their name in and press Tab, or alternatively use their player ID.

  • 1
    What first letter? Your second option is already given by someone else, it seems.
    – Joachim
    May 19, 2021 at 11:32
  • first solution still won't work
    – Penguin
    May 19, 2021 at 22:16

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .