I like to keep my hives about 400mm off the ground (give or take) to keep them from drowning and getting frosted in winter, and to allow a degree of airflow under the hive in summer, since my bottom boards are ventilated. There are lots of ways to get your hives off the ground that are basically "free" - all you need are some bricks, cinder blocks or the like. Many beekeepers build special pallets that serve the dual purpose of getting the bees off the ground and speeding up loading multiple hives onto a truck. Since my hives are more-or-less stationary, I'm less concerned with weight.
A stand for five hives.
How many hives you put together is up to you, but I like to keep my bees on 3 or 5 hive stands. Two hives feels like too few, and more than 6 hives on a stand that I want to be able to move with a truck is unwieldy. The cheapest way to make a 3 or 5 hive stand is with pallets (of course!) but then you have to make sure you're using pallets you trust, or seal them with something that you are confident won't off-gas something nasty up into your hives.
Down to the technical: my hives are 350mm square with a 400mm wide lid. I need about 30mm, give or take, between hives, just to comfortably fit a strap around the hive and shift them if needed. The stand should be at least 350mm wide just for stability. So a three hive stand needs to be about 1.3 metres long, and a five hive stand needs to be about 2.2 metres long. You could get really specific and I'm obviously rounding, but it just so happens that many pallets are 1200-1219mm long, which while not ideal are "good enough" with a little work. The 1200mm long ones can be tight with three hives but hey, free wood if free. If I'm buying my wood, it comes in 2.4m, 2.7m, 3.6m or 6m lengths, with longer wood being cheaper per metre.
All dimensions are nominal. Basically I just aim for equal spacing.
The difficult thing for me with using pallets is that the boards are almost never where I want them to be, so I end up using my hammer, pulling up all the boards, cutting them down, and then screwing them back down again where I want them. Since pine is relatively cheap, I buy some 35mm x 70mm and get it cut at Masters or Bunnings down to 350mm long chunks, and then affix black steel fence spikes to the bottoms, which makes the stand easier to level on rough ground. If I'm making a 5-hive stand I use new wood, and get the store to do all the cuts for me, so the only thing I need to do is screw them together when I get home. You can forgo the spikes altogether but I like the extra stability it gives the stand.
And that's it. So the TLDR version is this: there's no point getting fancy about your hive stand! I don't go fancy joinery on them (although I suppose I could). If your time is worth something I don't recommend pallets, because they take a long time to rip apart and put back together - but if you've got spare time to burn, working with pallets is fine in my opinion because they can often be had for free.