---
description: AbortController, AbortSignal, and WritableStream no longer throw when constructed during module evaluation.
title: AbortController and AbortSignal can be created at global scope
image: https://developers.cloudflare.com/changelog/post/2026-08-19-abort-signal-global-scope/og.png?v=b99437fda9621c10
---

[Skip to content](#main-content)

[View RSS feeds](https://developers.cloudflare.com/fundamentals/new-features/available-rss-feeds/) [ Subscribe to RSS](https://developers.cloudflare.com/changelog/rss/index.xml)

[Back to all posts](https://developers.cloudflare.com/changelog)

August 19, 2026

## AbortController and AbortSignal can be created at global scope

[Workers](https://developers.cloudflare.com/workers/)

Copy as Markdown| [View as Markdown](https://developers.cloudflare.com/changelog/post/2026-08-19-abort-signal-global-scope/index.md)| [Agent setup](https://developers.cloudflare.com/agent-setup/)

`new AbortController()`, `AbortSignal.abort()`, `new WritableStream()`, and `request.signal` no longer throw when used during module evaluation (that is, at the top level of your Worker module, outside of a request handler). Previously, these APIs required an active request context and would throw if called at the top level.

```js
// This now works — no error during module startup
const controller = new AbortController();

export default {
	async fetch(request) {
		// The signal can be used across requests
		return new Response("OK", { signal: controller.signal });
	},
};
```

Signals can also be observed and aborted across different requests, making it easier to coordinate cancellation in long-lived Workers such as Durable Objects.

`AbortSignal.timeout()` still requires an active request context because it needs to schedule a timer.

For more details, refer to the [AbortController documentation](https://developers.cloudflare.com/workers/runtime-apis/web-standards/#abortcontroller-and-abortsignal).

```json
{"@context":"https://schema.org","@type":"BlogPosting","@id":"https://developers.cloudflare.com/changelog/post/2026-08-19-abort-signal-global-scope/#page","headline":"AbortController and AbortSignal can be created at global scope","description":"AbortController, AbortSignal, and WritableStream no longer throw when constructed during module evaluation.","url":"https://developers.cloudflare.com/changelog/post/2026-08-19-abort-signal-global-scope/","inLanguage":"en","image":"https://developers.cloudflare.com/changelog/post/2026-08-19-abort-signal-global-scope/og.png?v=b99437fda9621c10","dateModified":"2026-08-19","datePublished":"2026-08-19","publisher":{"@type":"Organization","name":"Cloudflare","description":"One platform for your apps, agents, and workforce. Build, secure, and scale without managing infrastructure","url":"https://www.cloudflare.com/","sameAs":["https://github.com/cloudflare","https://www.linkedin.com/company/cloudflare","https://x.com/cloudflare"],"logo":{"@type":"ImageObject","url":"https://developers.cloudflare.com/logo.svg"},"address":{"@type":"PostalAddress","streetAddress":"101 Townsend St","addressLocality":"San Francisco","addressRegion":"CA","postalCode":"94107","addressCountry":"US"},"contactPoint":[{"@type":"ContactPoint","contactType":"Customer Support","url":"https://support.cloudflare.com/","availableLanguage":["English"]},{"@type":"ContactPoint","contactType":"Sales","url":"https://www.cloudflare.com/contact/","availableLanguage":["English"]}]},"isPartOf":{"@type":"WebSite","@id":"https://developers.cloudflare.com/#website","name":"Cloudflare Docs","url":"https://developers.cloudflare.com/"}}
```
