Updated:

Basics

/scoreboard objectives add points dummy "Points"
/scoreboard objectives setdisplay sidebar points
/scoreboard players add @p points 1

Create an objective called points, show it on the right of the screen, and add one point. dummy objectives only change through commands.

Count kills automatically (Java)

/scoreboard objectives add kills playerKillCount "Kills"
/scoreboard objectives setdisplay sidebar kills

playerKillCount goes up by one for every player killed. Use totalKillCount for all mobs and deathCount for deaths. Bedrock has no automatic criteria, so use a dummy objective and add to it yourself.

A countdown timer

A repeating command block runs 20 times a second, so 20 runs is one second.

# Setup
/scoreboard objectives add timer dummy
/scoreboard players set #game timer 1200
# Repeating, Always Active
/scoreboard players remove #game timer 1
# Chain, Always Active
/execute if score #game timer matches 0 run title @a title "Time!"

1200 is 60 seconds. Names starting with # are hidden from the sidebar, which makes them handy for internal values. To show seconds, divide by 20 into another score:

/scoreboard players set #20 timer 20
/scoreboard players operation #sec timer = #game timer
/scoreboard players operation #sec timer /= #20 timer

Announce a winner

/execute as @a if score @s points matches 10.. run title @a title {"selector":"@s"}

Shows the name of anyone with 10 or more points to everyone. Track the game state with a tag or score so the ending only runs once. See title and tellraw.

Reset

/scoreboard players reset @a points
/scoreboard objectives remove points

The first line clears everyone's points and keeps the objective; the second deletes the objective.

Bedrock Edition

Only dummy exists. Detect kills and deaths yourself and add to the score. Sidebar display, adding and comparing work the same way.

Common questions

For money and shops, see the scoreboard guide.

Check your command

The Command Error Doctor checks common syntax mistakes in your browser.