"Dedicate a work area for work and nothing else".
All I have on my work desk (which is an actual desk in a smallish room I converted for the purpose) is a monitor, keyboard and mouse and a coffee mug full of pens. The only thing in the room that isn't work is a Dualshock 4 PS4 controller that I use for gaming when I'm on lunch breaks or after work is done and I feel like playing some street fighter.
You don't just work at the house and expect to be productive. Much like muscles in the body working out for a marathon, you have to train at it, exercise and make deliberate efforts to get better. You don't just show up and run if you expect to have a good time.
YMMV though. I'm lucky to be a single-ish guy with a cat and no kids.