# Encryption

Every new Space is end-to-end encrypted, and a Space made before encryption gets there once its owner turns it on (see below). In an encrypted Space, your notes are locked on your device before they leave it, and only your devices and the people you let in can open them. Not even Niv can read them.

## Your passphrase and your recovery file

The first time you sign in, Niv asks for two things:

1. **Protect your notes.** Choose an **Encryption passphrase** of at least 12 characters, and type it once more.
2. **Save your recovery file.** Choose **Download recovery file** and keep it in two places, like a USB drive and a password manager. Tick **I saved my recovery file in two places** to go on.

Niv never sees your passphrase and can't reset it. If you forget it, the recovery file opens your notes. If you lose both, nobody can open them, including us: there is no copy of your key to fall back on. The Markdown files already on your devices stay readable there.

## On another device

Sign in, and Niv asks you to **Unlock your notes**: type your passphrase and choose **Unlock**. Forgot it? Choose **Use your recovery file**: you set a new passphrase, then choose the file.

## Settings › Encryption

- **Your key**: the fingerprint others can compare when they let you in.
- **Encryption passphrase**: **Change** it. It's instant; your notes aren't encrypted again.
- **Recovery file**: **Create a new one**. The old file stops working, so save the new one in two places.
- **Devices**: the devices that can open your notes. **Remove** one you no longer use.
- **Your Spaces**: how each Space's encryption is going.

On a Mac, your keys are kept in the Keychain until you sign out.

## New Spaces

Every new Space is encrypted from the start. Niv needs to reach its server before it can create one, so a new Space can't be made offline. See [Spaces](/p/docs/spaces).

## Letting people in

When someone joins an encrypted Space, they first set up their own passphrase. Then an owner or editor lets them in: in **Settings › Space › People**, choose **Let in…** next to their name. If you can, compare the key you see with the one they see in their **Settings › Encryption**. Until then, they see a line like "Waiting for someone in Atlas to let you in", with the Space's name. See [Members and roles](/p/docs/members-and-roles).

When someone leaves or is removed, the Space's key changes for the notes written from then on.

## Spaces made before encryption

A Space created before encryption stays as it was until its owner turns on encryption in the desktop app. Niv then encrypts every Space that owner owns, in the background: **Encrypting your Spaces**. There's no deadline, and Niv doesn't delete a Space for staying unencrypted.

Niv finishes a Space once all its members have turned on encryption. Until then, it says who it's waiting for. When it's done, the server's readable copy is gone. Published pages stay public.

## What works differently

- **Publishing** makes a readable copy of the note, with its images, on niv.md. See [Publish a note](/p/docs/publish-a-note).
- **Icons from the title** sends a new note's title, readable, to an AI model, unless you turn it off. See [Icons from the title](/p/docs/icons-from-the-title).
- **Images** show in Niv, but not in Obsidian or other editors.
- **Sync now** in **Settings › Space** doesn't work in encrypted Spaces yet.
- **Emails** from Niv don't name the Space or the note.

## What Niv's server still sees

Your email address and when you sign in; who is in each Space and their role; that a change happened, when, how large it was and whose device sent it; how many notes and folders a Space has and how they're arranged, without their names; your public keys, and a locked copy of your private keys.

The full list is at [niv.md/encryption](https://niv.md/encryption).

---

Published with [Niv](https://niv.md/) in the Space Docs.
