[API reference](https://evolu.dev/docs/api-reference) › [@evolu/common](https://evolu.dev/docs/api-reference/common) › [Task](https://evolu.dev/docs/api-reference/common/Task) › AbortError

```ts
const AbortError: typed("AbortError", {
  reason: AbortReason,
});
```

Defined in: [packages/common/src/Task.ts:1793](https://github.com/evoluhq/evolu/blob/037c390af081e9944d616ff298a729515c5c5ab7/packages/common/src/Task.ts#L1793)

Runtime Type for structured-concurrency abort control flow.

AbortError is thrown to stop [Task](https://evolu.dev/docs/api-reference/common/Task/type-aliases/Task) execution when a [Run](https://evolu.dev/docs/api-reference/common/Task/interfaces/Run) observes
an abort request. [AbortableFiber](https://evolu.dev/docs/api-reference/common/Task/interfaces/AbortableFiber) catches AbortError and returns it as
a [Result](https://evolu.dev/docs/api-reference/common/Result/type-aliases/Result) error, so abort can be handled as an ordinary Task outcome.

The reason explains why the Run was aborted. It can be an explicit abort
reason, [runDisposedAbortReason](https://evolu.dev/docs/api-reference/common/Task/variables/runDisposedAbortReason) for normal Run cleanup, or
[PanicAbortReason](https://evolu.dev/docs/api-reference/common/Task/interfaces/PanicAbortReason) when a defect panicked the Run tree. The original
defect is available as `panicAbortReason.defect` for diagnostics.

AbortError is reserved for Task abort control flow. Do not throw or reject
with AbortError for domain errors; return a Result error instead.

Helpers that abort their own child Tasks should catch or normalize AbortError
before it escapes the helper boundary. The reason carries typed domain data.

WebKit fetch rejects with its own abort error instead of `signal.reason`.
Native wrappers should treat `signal.reason` as the source of truth and
normalize aborts to AbortError.