JavaScriptMedium
Explain the event phases in a browser
By FrontendPro Editorial Team Updated 8/8/2026
#JavaScript
Answer
In a browser, events go through three phases: capturing, target, and bubbling. During the capturing phase, the event travels from the root to the target element. In the target phase, the event reaches the target element. Finally, in the bubbling phase, the event travels back up from the target element to the root. You can control event handling using addEventListener with the capture option.
