The simulation shows the magnetic field from a current loop. We're looking at the side of the loop.
Which way is the current?
For loops like this our color code will be red for out of the screen and blue for into the screen.
There are strong parallels between a bar magnet and a current loop. Magnetic fields come from currents and in a bar magnet the fact that there is a net alignment of the electron spins is equivalent to a current running around the magnet.