When you choose a board, the brand will have a recommended size chart based on weight and boot size. You want to be sure to not have any boot drag off the side of the board!
You’ll also want to consider your height and the type of riding you want to do. Back in the day, folks would stand the snowboard next to themselves and if the board reached between the chin and nose, that indicated the correct size. You can get an idea of the snowboard size with that method, but be sure to consider your weight and boot size, too.
Generally, if you want to ride more aggressively and in steeper, faster, rugged conditions, a longer board can help drive more control, damping, and power. A shorter board will be snappier, quicker to steer, and easier to ollie. It’s often a good choice for riding through the park, tight glades, and moguls.
Ultimately, the best size comes down to personal preference, so try to demo or rent a few boards before buying your own.