Got to this point on my shepherd's hut build a couple of years back and it had me scratching my head too. Earthing a detached outbuilding is one of those things where people do all sorts but there's definitely a right way.
For a shed office fed by its own supply (whether that's solar or mains cable from the house), you'll generally want a TT earthing system — that means driving an earth rod into the ground rather than relying on the supply cable's earth. Any detached structure really should have this, and it needs to be paired with an RCD at the consumer unit because earth rod resistance is typically higher than a TN system.
A few things worth checking:
- Earth rod depth matters — resistance needs to be low enough for the RCD to trip reliably under fault conditions. 1.2m minimum, deeper if your soil is sandy or dry
- If you're running off solar with a Victron system, the earthing arrangement changes slightly depending on whether you're running a neutral-earth link — worth checking the Victron docs
- An EICR from a qualified sparks before you start using it properly is worth every penny, even on a small outbuilding
Is your supply coming from the house via SWA cable or is this a standalone solar setup? Makes a difference to how you'd approach it. Also, what CU are you using — some of the cheaper units make compliant RCD protection harder to achieve neatly.
Happy to share what I ended up doing on mine if it helps — took a few iterations to get right.