Contrary to popular belief, it is possible to be highly productive with a home office, even if you have kids, I should know that is what I do. And I have a five year old and I've done this her throughout her entire life. So it can be done but you need to make some adjustments for starters, if you have family members who are just used to grabbing you at any time, you need to be able to have a Do Not Disturb sign on a door. Perhaps you need a separate part of the house. Maybe that's not possible. If nothing else do you need to wear noise cancelling headphones so you can concentrate on what you're doing, even if their family members yelling back and forth.
I do think it's far better to have a separate room that's not always possible. If you live in a big city where everything as a studio apartment and space is at a premium but if at all possible, even an old girl garage, or even a large closet if you can make that a place just for work, it can make you more effective and more productive. Sometimes just the act of closing the door puts you in a different frame of mind. The famous journalist and author, Tom Wolf would dress up elaborately. He would wear Spats, white shirt, white, white coat, white suit, pink ties, he was known as just an elaborate, consummate clotheshorse. He would dress himself up every day, just to work from home writing.
Now, I don't go to that extreme. I'm not saying you need to as well. But if there's something that puts you into a work frame of mind, do it. If you have distractions, you've got to figure out how to minimize them. So you You can be productive. Don't just tell yourself it's a home office, I'll never get an A done and complain.
Find a solution could be earplugs, which I've used before. It could be noise cancelling headphones, it could be listening to some music, if it's not distracting doors, talking to family members saying, Please, I'm going to have to have time alone. Sometimes the configuration of the house. Think of all of those factors do whatever it takes to make sure you have a work environment, free of distractions.