Your own bar at the top of the screen, for an event, a countdown or a server message. Set the name, the colour and how full it is, see it, and copy the /bossbar commands.
Commands
Run them in this order. Chat takes one command at a time.
Later
What each part does
Bar id: the short name you use for this bar in every command. Small letters, numbers and _.
Filled ... of ...: the bar is full when both numbers are the same and empty at 0.
Style: cuts the bar into pieces. It changes the look only.
Shown to: @a shows the bar to everyone who is online at that moment.
Name: &a to &f and &0 to &9 are the 16 colours, 7FF99 is any hex colour, &l is bold.
Good to know
A new bar starts white, in one piece, empty, with 100 as the full amount. The tool leaves out the commands that would set those same values, because the game answers them with "Nothing changed".
Players who were not online when you ran the last command do not see the bar. Run the "show it again" command, for example from a repeating command block.
The bar stays until you remove it, also after a restart.
The way the name is written changed in 1.21.5. Pick your version so the first command is in the form your server expects.
You need operator rights, or cheats turned on, to use /bossbar.
Something wrong or missing here? Tell me, requests decide what I add next. More tools: all tools.