---
editLink: false
lastUpdated: false
---

[@salesforce/b2c-tooling-sdk](../../modules.md) / [errors](../index.md) / isNetworkError

# Function: isNetworkError()

> **isNetworkError**(`err`): `boolean`

Defined in: [packages/b2c-tooling-sdk/src/errors/network-error.ts:197](https://github.com/SalesforceCommerceCloud/b2c-developer-tooling/blob/0c642abce71b645ae9df3c6046c2bf8396a2845c/packages/b2c-tooling-sdk/src/errors/network-error.ts#L197)

Checks if an error is a network-layer error (not an HTTP/application error).

Returns true for thrown network errors like "fetch failed", AbortError, TimeoutError,
or errors with recognizable network error codes.

Returns false for HTTPError and other application-level errors that should pass through untouched.

## Parameters

### err

`unknown`

The error to check

## Returns

`boolean`

true if this is a network error
