I'd say it depends on what you're shooting. I have a d5600 and Z5.
The Z5 is better for baby pictures.
The d5600 is still better for hiking and travel pictures.
The Z5 is better under low-light and dynamic subject conditions. Particularly because the digital viewfinder is clearer in the dark, the eye/face autofocus and low light autofocus performance is much better (much fewer missed shots), the Z5 has sensor-shift stabilization, and there is no mirror slap affecting lower shutter speeds. For landscapes where there is lots of light, a lightweight and battery conservative d5600 still does the job excellently.
The Z5 is better for baby pictures.
The d5600 is still better for hiking and travel pictures.
The Z5 is better under low-light and dynamic subject conditions. Particularly because the digital viewfinder is clearer in the dark, the eye/face autofocus and low light autofocus performance is much better (much fewer missed shots), the Z5 has sensor-shift stabilization, and there is no mirror slap affecting lower shutter speeds. For landscapes where there is lots of light, a lightweight and battery conservative d5600 still does the job excellently.