| CARVIEW |
Select Language
HTTP/2 302
x-cloud-trace-context: bfed94aa55c684c41b66a10ecd6198b0
location: /en-US/docs/Web/API/MessageEvent/origin
via: 1.1 google, 1.1 varnish, 1.1 varnish, 1.1 varnish, 1.1 varnish
accept-ranges: bytes
cache-control: no-store
server: Google Frontend
content-type: text/plain; charset=utf-8
date: Mon, 29 Dec 2025 20:41:35 GMT
x-served-by: cache-bfi-krnt7300117-BFI, cache-bfi-krnt7300069-BFI, cache-sin-wsss1830094-SIN, cache-bom-vanm7210057-BOM
x-cache: MISS, MISS, MISS, MISS
x-cache-hits: 0, 0, 0, 0
x-timer: S1767040895.245959,VS0,VE346
vary: Accept
content-length: 61
HTTP/2 200
x-guploader-uploadid: AHVrFxNAiUl8uZDeShVMZMT3lT_QSX1Qykn8xClq8MA1ZFqkl1VqL_f4yeAaB0dZrXNxJU38
cache-control: public, max-age=3600
x-goog-hash: crc32c=f9fFFg==, md5=u/LmsoCCcqr8wsh8nVZlJw==
x-cloud-trace-context: bb77023cf629da8084cb31ab4a8cb1e0
x-frame-options: DENY
via: 1.1 google, 1.1 varnish, 1.1 varnish, 1.1 varnish, 1.1 varnish
server: Google Frontend
expires: Mon, 29 Dec 2025 17:59:55 GMT
last-modified: Mon, 29 Dec 2025 01:08:29 GMT
x-goog-stored-content-length: 146628
x-goog-metageneration: 1
strict-transport-security: max-age=63072000
x-goog-meta-goog-reserved-file-mtime: 1766969340
x-content-type-options: nosniff
x-goog-storage-class: STANDARD
x-goog-stored-content-encoding: identity
origin-trial: AxVILwizhbMjxFeHOn1P3R8niO1RJY/smaK4B4d1rLzc1gTaxtXMSaTi+FoigYgCw40uFRDwFcEAeqDR+vVLOW4AAABfeyJvcmlnaW4iOiJodHRwczovL2RldmVsb3Blci5tb3ppbGxhLm9yZyIsImZlYXR1cmUiOiJQcml2YXRlQXR0cmlidXRpb25WMiIsImV4cGlyeSI6MTc0MjA3OTYwMH0=
content-type: text/html
referrer-policy: strict-origin-when-cross-origin
content-security-policy: default-src 'self'; script-src 'report-sample' 'self' 'wasm-unsafe-eval' https://www.google-analytics.com/analytics.js https://*.googletagmanager.com assets.codepen.io production-assets.codepen.io https://js.stripe.com 'sha256-XNBp89FG76amD8BqrJzyflxOF9PaWPqPqvJfKZPCv7M=' 'sha256-YCNoU9DNiinACbd8n6UPyB/8vj0kXvhkOni9/06SuYw=' 'sha256-PZjP7OR6mBEtnvXIZfCZ5PuOlxoDF1LDZL8aj8c42rw='; script-src-elem 'report-sample' 'self' 'wasm-unsafe-eval' https://www.google-analytics.com/analytics.js https://*.googletagmanager.com assets.codepen.io production-assets.codepen.io https://js.stripe.com 'sha256-XNBp89FG76amD8BqrJzyflxOF9PaWPqPqvJfKZPCv7M=' 'sha256-YCNoU9DNiinACbd8n6UPyB/8vj0kXvhkOni9/06SuYw=' 'sha256-PZjP7OR6mBEtnvXIZfCZ5PuOlxoDF1LDZL8aj8c42rw='; style-src 'report-sample' 'self' 'unsafe-inline'; object-src 'none'; base-uri 'self'; connect-src 'self' developer.allizom.org bcd.developer.allizom.org bcd.developer.mozilla.org updates.developer.allizom.org updates.developer.mozilla.org https://*.google-analytics.com https://*.analytics.google.com https://*.googletagmanager.com https://incoming.telemetry.mozilla.org https://observatory-api.mdn.allizom.net https://observatory-api.mdn.mozilla.net https://api.github.com/search/issues stats.g.doubleclick.net https://api.stripe.com; font-src 'self'; frame-src 'self' mdn.github.io *.mdnplay.dev *.mdnyalp.dev *.play.test.mdn.allizom.net https://v2.scrimba.com https://scrimba.com jsfiddle.net www.youtube-nocookie.com codepen.io survey.alchemer.com https://js.stripe.com; img-src 'self' data: *.githubusercontent.com *.googleusercontent.com *.gravatar.com mozillausercontent.com firefoxusercontent.com profile.stage.mozaws.net profile.accounts.firefox.com developer.mozilla.org mdn.dev wikipedia.org upload.wikimedia.org https://mdn.github.io/shared-assets/ https://mdn.dev/ https://*.google-analytics.com https://*.googletagmanager.com www.gstatic.com; manifest-src 'self'; media-src 'self' archive.org videos.cdn.mozilla.net https://mdn.github.io/shared-assets/; child-src 'self'; worker-src 'self';
etag: "bbf2e6b2808272aafcc2c87c9d566527"
x-goog-generation: 1766970509585263
content-encoding: gzip
accept-ranges: bytes
age: 0
date: Mon, 29 Dec 2025 20:41:36 GMT
x-served-by: cache-bfi-kbfi7400110-BFI, cache-bfi-kbfi7400110-BFI, cache-sin-wsat1880091-SIN, cache-bom-vanm7210057-BOM
x-cache: MISS, HIT, HIT, MISS
x-cache-hits: 0, 7, 0, 0
x-timer: S1767040896.605262,VS0,VE478
vary: Accept-Encoding
content-length: 19471
MessageEvent: origin property - Web APIs | MDN
Toggle sidebar
>
MessageEvent: origin property
Baseline
Widely available
This feature is well established and works across many devices and browser versions. It’s been available across browsers since July 2015.
Note: This feature is available in Web Workers.
The origin read-only property of the
MessageEvent interface is a string representing the
origin of the message emitter.
Value
A string representing the origin.
Examples
js
myWorker.onmessage = (e) => {
result.textContent = e.data;
console.log("Message received from worker");
console.log(e.origin);
};
Specifications
| Specification |
|---|
| HTML> # dom-messageevent-origin-dev> |
Browser compatibility
See also
ExtendableMessageEvent— similar to this interface but used in interfaces that needs to give more flexibility to authors.