Although aggressive behavior in children and adolescents with attention-deficit/hyperactivity disorder (ADHD) has previously shown correlations with hyperactivity/impulsivity, few studies have examined its association with inattention or the effect of working memory on aggressive behavior. This study aimed to assess the relationship between inattention and aggressive behavior and the effect of working memory on the relationship between inattention and aggressive behavior in children and adolescents with ADHD. Thirty-one children and 26 adolescents with ADHD were retrospectively investigated. The subjects completed the Korean Wechsler Intelligence Scale for Children-Fourth Edition (KWISC-IV), the Korean Child Behavior Checklist (K-CBCL), and the Korean Children's Depression Inventory (CDI). Inattention was positively correlated with aggressive behavior in children and adolescents with ADHD and working memory showed an insignificant correlation. However, working memory had a significant moderating effect on aggressive behavior by interacting with inattention. The moderating effect of working memory manifested when the working memory index score on the K-WISC-IV was 73.5 points or higher, and it had a significant effect on aggressive behavior. This study shows that the severity of inattention and hyperactivity/impulsivity should be addressed to provide appropriate treatment to children and adolescents with ADHD who exhibit aggressive behavior. Copyright © 2020 Korean Academy of Child and Adolescent Psychiatry.