I was halfway through lunch preparations and the water for pasta was about to boil over. My kids were out on the deck playing and for the moment, all was quiet.

Then came my son, announcing that he was ready to come inside. He also claimed that my daughter wanted to come in, too, even though she was still happily playing. As he continued to argue his case, the sizzling sound of water boiling over echoed through the kitchen. And still my son stood in the doorway.

I knew the chicken nuggets were probably already burning and now my daughter was also trying to get through the doorway, ready to make a beeline for the oven. And so I did the only thing I could do.

I yelled.

I yelled at my son. I committed what felt like the ultimate parenting faux pas. Even though there are countless articles and books out there about resisting the urge to yell at our children (and I’d read plenty of them), I did it anyway.

I wasn’t even angry. I was frustrated with him, sure, and I was worried about ruining lunch, but I wasn’t angry. I just needed him to come inside and close the door. So I did the only thing that I knew would guarantee that he’d come in. I yelled at him.

The effect was instantaneous. He began to cry. He closed the door. He went into the living room to retrieve his teddy bear. I continued preparing lunch as I debated the appropriateness of my actions. Was I wrong to have yelled? Was there something else that I could have done? Had I damaged my relationship with my son by yelling?

Less than five minutes later, my son was in my arms chatting with me as if nothing had happened. Only the salt stains on his cheeks were left as proof. And as we sat down to lunch, I realized something important.

Sometimes you just need to yell. Sometimes yelling is the only way to guarantee that you’ll be heard. And at that moment, I needed to be heard.

I don’t yell very often. In fact, I can count on one hand the number of times that I’ve really yelled at my children. I’m just not much of a yeller. It’s probably the biggest reason my son responded immediately. Yelling is not normal in our house. But at that moment, I needed my son to listen to me, so I did the only thing I knew would get him to hear me.

I didn’t do it out of anger. I did it because I needed to be heard. With the oven beeping, the water boiling over and both of my children talking incessantly, I couldn’t run the risk of my voice being drowned out. I needed my son to listen to me for safety purposes—I didn’t want both of them to run in right toward the hot oven. I just needed him to listen.

Yelling doesn’t always have to be bad. When a child is in danger, yelling might be the most effective way of keeping a child safe. When the environment is loud, yelling might be the most effective way of being heard.

I’m not advocating yelling all the time—I think my yelling was only effective because it is so rare. I don’t generally yell at my kids, and I try really hard not to yell out of anger. I don’t want to scare my son, but I do want him to listen. I need him to listen, especially when someone’s safety is on the line.

Most importantly, I know I’m not ruining my relationship with my son if I yell at him every once in a while. Occurrences are few and far between, and I know he falls asleep every night knowing I love him.

After I yelled, I spent a few minutes wondering if I had done the right thing, but by the time we sat down to lunch, all was well in my son’s world again. I knew everything was fine the moment he came to sit in my lap, looking for comfort. He still came to me even though I’d yelled at him. Because he knew I would hold him. Because he knew I would comfort him. Because he knew I loved him.

And when love is overflowing and yelling is rare, that’s all that matters.

So, mama, know that sometimes we’re going to yell—we’re only human, after all—but it doesn’t make you a bad mom. We’re doing okay.