All commands
๐Ÿงฎ
AdvancedJava โœ“Bedrock โœ“

/scoreboard

Create objectives and keep score - the foundation of mini-games.

Overview

What is the /scoreboard command?

The /scoreboard command creates objectives and tracks numbers for players and entities โ€” kills, deaths, custom counters, timers and triggers. Combined with /execute, scoreboards are how datapacks store variables and build logic, and they also power the visible sidebar and below-name displays.

If /execute is the processor, scoreboards are the memory: nearly every non-trivial command system uses them.

When to use it: Use /scoreboard to track scores and store variables โ€” kill counts, timers, minigame points, and datapack logic.

At a glance

Syntax

Syntax
/scoreboard objectives add <name> <criteria>
commandtargetcoordsvaluerequiredoptional

See it

What it does

Kills
Alex
Steve
Notch
+1
Tracking scores on an objective

Anatomy

Every part, explained

  1. 1
    /scoreboardCommandRequired

    Manages objectives and player scores.

  2. 2
    objectives addActionRequired

    Also: 'players add/set/get' to change scores.

  3. 3
    <name>NameRequired

    Your id for the objective, e.g. kills.

  4. 4
    <criteria>CriteriaRequired

    What it tracks, e.g. dummy, playerKillCount.

Your turn

Try it yourself

Playground
5 tokens ยท press Enter to run

Copy & paste

Examples

/scoreboard objectives add kills playerKillCount

Track player kills automatically.

/scoreboard players set @s kills 0

Reset your kill score.

/scoreboard players add @s kills 1

Manually add a point.

Avoid these

Common mistakes

โœ•/scoreboard add kills dummy
โœ“/scoreboard objectives add kills dummy

You must say 'objectives' (or 'players') first.

โœ•/scoreboard objectives add kills kill
โœ“/scoreboard objectives add kills playerKillCount

Use a valid criteria name.

Good to know

Frequently asked questions

How do you create a scoreboard objective?
Run /scoreboard objectives add <name> <criterion>, e.g. /scoreboard objectives add kills playerKillCount.
How do you show a scoreboard on the sidebar?
Use /scoreboard objectives setdisplay sidebar <name> to display it on the right side of the screen.
How do you set or change a player's score?
Use /scoreboard players set <player> <objective> <value>, or add/remove to adjust it.

Keep going

Related commands