# SecurityApi.isEncrypted

```ts
get isEncrypted(): boolean
```

Whether the document is encrypted. A getter: answers at once, and throws `DOCUMENT_CLOSED` on a closed document.

- Kind: getter
- Since: 1.0.0

Returns `boolean`

Throws:

- `DOCUMENT_CLOSED` — read on a closed document.

```ts
if (doc.security.isEncrypted) badge.hidden = false;
```

Part of [SecurityApi](https://kernstra.com/docs/web-sdk/api/doc-security) in the Kernstra Web SDK 1.0.0 API reference.

Web page: https://kernstra.com/docs/web-sdk/api/doc-security/isencrypted
