> ## Documentation Index
> Fetch the complete documentation index at: https://docs.alkera.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Files

> All the files from all of your workspaces, plus files shared with you.

**Files** holds all the files from all of your workspaces, plus files shared with you.

Open it from **Files** in the sidebar.

## Places

The left rail has:

| Place | What it shows |
| - | - |
| **Home** | Your own files and folders, including your workspaces. |
| **Recent** | What you opened or changed lately. |
| **Shared with me** | Files, folders, and workspaces others shared with you. |
| **My leases** | Folders a machine is working in for you right now. See [Where workspace files live](#where-workspace-files-live). |
| **Trash** | Deleted items, kept for 30 days. |

## Work with files

Right-click any item for its actions, or use the toolbar.

* **Create**: **New folder**, **New notebook**. Notebooks can be created only inside a workspace.
* **Upload**: **Upload files** or **Upload folder**, or drag them in. A single file can be up to 1 TB.
* **Organize**: **Rename**, **Move to…**, **Copy to…**, **Duplicate**, and cut, copy, and paste.
* **Get it out**: **Download**, **Copy link**.
* **History**: **Versions** and **Details**.

Uploading over an existing file asks first. **Replace** keeps the file and adds your upload as a new version. Alkera keeps at least the newest five versions of a file, and every version from the last 90 days.

## Previews

Click a file to preview it without downloading.

| Kind | Formats |
| - | - |
| Tables | CSV, TSV |
| Documents | PDF, Markdown, HTML, plain text and logs |
| Code and config | Most languages, plus JSON, YAML, TOML, and similar |
| Images | PNG, JPEG, GIF, WebP, AVIF, SVG, and others |
| Media | MP3, WAV, M4A, AAC, OGG, FLAC, MP4, WebM, MOV |
| Notebooks | Alkera notebooks (`.alknb.py`), read-only, with their saved outputs |

Office documents and other formats show a file card that you can download.

## Where workspace files live

A workspace's files have one home: its folder in Files. The [machine](/workspaces/machines) only holds a working copy, and only while the workspace is awake.

```mermaid theme={null}
flowchart LR
  asleep["<b>Asleep</b><br/>Only in Files<br/>Nothing on machine"]
  awake["<b>Awake</b><br/>Copy on machine<br/>Synced with Files"]
  asleep -- "<b>Wake</b><br/>Copy to machine" --> awake
  awake -- "<b>Sleep</b><br/>Save, then clear" --> asleep
```

**While the workspace is asleep**, its files are only in Files. You can browse, preview, upload, and share them as usual. Nothing is on any machine.

**When it wakes**, Alkera copies the folder from Files onto the machine. On the machine, it is the agent's working directory, `/home/alkera`.

**While it is awake**, the working copy and Files stay in sync:

* Files the agent or a notebook writes on the machine appear in Files within moments.
* Files you upload or edit in Files reach the machine.
* If a file changes in both places at once, Alkera keeps both, saving one as a conflicted copy next to it.
* Files larger than 32 MiB that are written on the machine are not copied live. They reach Files when the workspace sleeps or moves.

While a machine is working in a folder, it holds a **lease** on it, and the folder shows who is working in it.

**When it sleeps**, Alkera saves the whole folder to Files, releases the lease, and clears the folder from the machine. Files then holds the latest copy. See [Sleep and wake](/workspaces/overview#sleep-and-wake) for when that happens.

**When it moves** to another machine, the same thing happens: the folder is saved to Files, then copied onto the new machine.

<Note>
  Some things never leave the machine: caches and build folders, such as `.venv`, `node_modules`, and `__pycache__`, and files matched by a `.gitignore`. They are gone after the workspace sleeps or moves.
</Note>

## Sharing

Right-click a file or folder and choose **Share…**. Add people, teams, or everyone in the organization, and pick their access:

* **Can view**: open, preview, download, and copy.
* **Can edit**: also change, rename, and upload.
* **Full access**: also share and delete.

Access granted on a folder carries to everything inside it and shows as **Inherited**. Sharing a workspace's folder shares the workspace. See [Workspaces](/workspaces/overview#sharing).

## Trash

**Move to trash** removes an item from its folder. Deleting a workspace or a chat moves its files to the trash too.

Open **Trash** to **Restore** an item to where it was, or **Delete forever**. Items are deleted for good after 30 days. **Empty trash** deletes everything in it right away.

## Storage

Storage counts toward your organization's [plan](/organization/billing). Identical files are stored once across your organization, but each copy still counts toward your usage. Admins can set storage limits per team and per member.

## Related

<Columns cols={2}>
  <Card title="Workspaces" icon="folder-open" href="/workspaces/overview">
    The folder behind every workspace.
  </Card>

  <Card title="Notebooks" icon="book" href="/notebooks/overview">
    Notebooks are files in a workspace's folder.
  </Card>
</Columns>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.