JavaScript Event explicitOriginalTarget Property

Beginner
5 min read
Updated: Nov 2026
3 examples
Property

Definition

Event.explicitOriginalTarget is a read-only Mozilla property that returns the non-anonymous original EventTarget of the event (or null). (MDN: also noted as available in Web Workers where the engine supports it.)

Read the notes below before you rely on this property. Prefer feature detection when support is limited.

Syntax

Use event.explicitOriginalTarget. Start with this line.

JavaScript
event.explicitOriginalTarget
CallWhat it does
event.explicitOriginalTargetPrimary signature.

Built into the browser. Read event.explicitOriginalTarget on an Event instance — no import required.

Library declarations
JavaScript
event.explicitOriginalTarget

Parameters

ParameterDescription
Feature detectRequired. Property may be missing

Return Value

Return ValueDescription
*The current value of event.explicitOriginalTarget.

JavaScript Examples

Example 1 — Feature-Detect Support

Check whether this browser exposes the property before reading it.

JavaScript
button.addEventListener("click", (event) => {
  if ("explicitOriginalTarget" in event) {
    console.log("supported");
    console.log(event.explicitOriginalTarget.nodeName);
  } else {
    console.log("not available — use event.target");
    console.log(event.target.nodeName);
  }
});
Try It Yourself

How It Works

  1. Listen for click. The handler receives a real Event.
  2. Detect first. in checks whether the property exists on that event.
  3. Firefox path. If present, log the original target’s nodeName.
  4. Fallback. Otherwise use standard event.target.

Example 2 — Compare with event.target

Print both names side by side (unsupported browsers show a clear fallback).

JavaScript
box.addEventListener("click", (event) => {
  const eot = ("explicitOriginalTarget" in event)
    ? event.explicitOriginalTarget
    : null;

  console.log("target:", event.target.nodeName);
  console.log(
    "explicitOriginalTarget:",
    eot ? eot.nodeName : "(unsupported)"
  );
});
Try It Yourself

How It Works

  1. Read the standard target. event.target works everywhere.
  2. Optionally read EOT. Only if the property exists.
  3. Compare names. On many clicks they match; Firefox text-node cases may differ.
  4. Stay portable. Treat missing support as normal outside Firefox.

Example 3 — Click Paragraph Text

In Firefox, clicking the letters may show #text on explicitOriginalTarget.

JavaScript
para.addEventListener("click", (event) => {
  console.log("target:", event.target.nodeName);

  if ("explicitOriginalTarget" in event && event.explicitOriginalTarget) {
    console.log(
      "explicitOriginalTarget:",
      event.explicitOriginalTarget.nodeName
    );
  } else {
    console.log("explicitOriginalTarget: (unsupported)");
  }
});
Try It Yourself

How It Works

  1. Click the letters. The deepest node can be a text node.
  2. Standard target. Engines often report the parent <p>.
  3. Firefox original. When supported, EOT may still be #text.
  4. Learning goal. Understand retargeting — still prefer event.target in apps.

Browser Support

Event.explicitOriginalTarget is marked Non-standard on MDN. It is a Mozilla-specific property (mainly Firefox / Gecko), not part of a web specification.

✓ Non-standard · Firefox

Event.explicitOriginalTarget

Read-only non-anonymous original EventTarget. Expect support primarily in Firefox; feature-detect everywhere else.

Limited Firefox-focused
Mozilla Firefox Supported · Gecko
Supported
Google Chrome Not available
No support
Apple Safari Not available
No support
Microsoft Edge Not available
No support
Opera Not available
No support
Internet Explorer Not a portable API
No support
explicitOriginalTarget Non-standard

Bottom line: Use for Firefox learning and legacy Gecko code only. Portable apps should rely on event.target (and composedPath() when you need the path).

Frequently Asked Questions

It is a read-only, Mozilla-specific Event property that returns the non-anonymous original EventTarget of the event (or null). MDN marks it Non-standard.
MDN marks it Non-standard only—not Deprecated or Experimental. It is not part of any web specification and is not on track to become a standard. Prefer event.target for portable code.
In Firefox, some events (for example mouse events over text nodes) are retargeted to a parent element. event.target often shows that parent, while explicitOriginalTarget can still point at the original text node.
Both are Mozilla-specific. MDN says explicitOriginalTarget never contains anonymous content, while originalTarget may. Neither should be used in cross-browser production apps.
Primarily Firefox (Gecko). Chrome, Safari, and Edge generally do not expose it. Always feature-detect before reading.
For portable apps use event.target (and event.currentTarget when you need the listener host). For path inspection, consider event.composedPath() where available.

Next: isTrusted

See whether the browser created the event or your script did.

isTrusted tutorial →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

7 people found this page helpful