Harsh contrast almost always comes from two things: too big a jump in lightness (LRV), or two colours fighting on undertone. Sort both and you get contrast that has presence without slapping you in the face.
The single best move is to work tonally within one colour family. Instead of pairing a bright white with a near-black, step through a graduated set of related shades. Farrow & Ball's grey-greens do this beautifully — Mizzle on walls, Pigeon or Treron on joinery. The difference is real, the eye reads depth, but because they share that soft green-grey undertone there's no jarring seam where they meet.
The other approach is to borrow contrast from texture and sheen rather than hue. A matt wall against the same colour in an eggshell or satin trim gives you a subtle shift that catches the light differently through the day. Little Greene and Mylands both do gorgeous trim finishes that let you do this within a single shade.
If you genuinely want a darker accent — a chimney breast, a panelled wall — choose one that sits in the family rather than opposing it. Inchyra Blue or Card Room Green against a warm off-white like Pointing lands soft because the warmth runs through both. The classic mistake is reaching for a brilliant white, like Strong White's cooler cousins, alongside a deep colour — that cool brightness is exactly what makes it shout.
The "but what about a feature wall?" question: a feature wall isn't harsh because it's dark, it's harsh because it floats with nothing tying it to the rest of the room. Pull the accent colour into a cushion, a lampshade, the trim — give it two or three touch-points and the contrast settles instantly.
Practical advice: never judge contrast from a fan deck. Get large sample pots, paint A2 boards, and stand them side by side in the actual room at morning and evening. If the join between two colours makes you squint, soften the lighter one or deepen the darker one until it doesn't. Trust your eye over any rule.