Skip to content
lyfie-orgPublic

About

Star if Papyra keeps your notes yours! A self-hosted, Google Keep-style notes app where every note is a plain Markdown file on your disk. Live collaboration, passkeys, encrypted locked notes, full-text search and one-container Docker setup. Crafted with 💗 for people who want their notes without lock-in.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

164 stars

Watchers

1 watching

Forks

Papyra logo

Papyra

A calm, self-hosted home for your notes.
Google Keep–style notes on your own server, where every note is a plain Markdown file.

Latest release Docker pulls License: GPL v3 Join us on Discord

Try the demo · Website · Docs · Discord

Papyra | AlternativeTo

The Papyra desk: pinned and coloured note cards in a warm, paper-like grid

Why Papyra

  • Your notes are just files. Each note is a .md file with a small YAML header, in a folder you own. If you ever stop using Papyra, you still have a folder of Markdown. (Locked notes stay encrypted, so keep their keys with your backups.)
  • One container, one volume. No database server, no search server. It runs on amd64 and arm64, so a Raspberry Pi 4 or 5 is plenty.
  • It plays well with your other tools. Obsidian, VS Code, grep, Syncthing and git can all work on the same folder, and Papyra notices outside changes and catches up.
  • It keeps to itself. No tracking, analytics or crash reports, and no request to any server of ours. Once a day Papyra looks at GitHub for a newer version and sends nothing about you. You can turn that off with PAPYRA_UPDATE_CHECK_ENABLED: "false" (what it asks).

A shell appends a line to a note's file and the open app updates on its own
Change the file from anywhere and the app catches up on its own.

Install

You need Docker with Compose.

curl -O https://raw.githubusercontent.com/lyfie-org/papyra/main/docker-compose.hub.yml
docker compose -f docker-compose.hub.yml up -d

Open http://localhost:8080 and create the first account.

Running it on a server or NAS? A few things worth knowing
  • HTTPS and reverse proxies: put Papyra behind Caddy, Traefik, Nginx Proxy Manager or a Cloudflare Tunnel. See HTTPS.
  • Opening it by IP over plain http (for example http://192.168.1.50:8080, or a Tailscale address)? Set PAPYRA_ALLOW_INSECURE_COOKIES: "true" in the compose file, or the browser won't keep you signed in. Restart it afterwards with the up -d command above. Only do this on a network you trust.
  • File ownership: PUID and PGID in the compose file decide who owns the files in the volume, so you can edit them over SMB or Syncthing.
  • Notes in a folder you can see: swap the named volume for a bind mount such as ./papyra-data:/data. See Your files.
  • Updating: docker compose -f docker-compose.hub.yml pull && docker compose -f docker-compose.hub.yml up -d.
  • Backing up: copy the whole data volume, hidden .papyra folders included. Locked notes can't be opened without the keys kept there.
  • Every setting: Configuration.

What you get

Write without a save button

Click a card and type. Papyra saves when you pause, works offline, and syncs when you're back.

A note open in the focused editor

Find what you wrote

Press Ctrl + K to search titles, text and tags, with the matches highlighted.

Typing in search narrows the results and highlights matches

Write together

Share a note and edit it at the same time, with named cursors. It is still a .md file on disk.

Two people editing the same note with named cursors

A vault for private notes

Locked notes are blurred everywhere, open with a PIN or your fingerprint, and are encrypted on disk.

Typing the vault PIN opens a locked note

History for every note

Step back through earlier versions, see what changed, and restore the one you want.

The history view comparing two versions of a note

Comments and links

Select text to comment. Type [[ to link to another note, and each note lists what links back to it.

A note with highlighted passages and comment threads

A day of the Papyra journal: the date, how the day felt, a few lines of writing and a ticked list
A journal, too. One page for each day, with moods, a calendar, voice notes and days you can lock. They are plain Markdown files as well, and export as files or a PDF book.

And more: notifications by email, ntfy, Discord or Telegram · pictures and PDFs inside notes · to-do lists · tags and smart collections · sharing with people or by link, with an expiry · passkeys, an authenticator app and single sign-on (OIDC) · import from Obsidian, Google Keep and Day One · export everything to a zip · encrypted backups of your notes and of the server · backup to a private GitHub repo · installs as an app on your phone.

Papyra on a phone

Your first ten minutes

  1. Create your account. A short setup asks for a username, an authenticator app, an email, a password and a Vault PIN. If you are restoring a backup instead, that option is on the first screen.
  2. Bring your notes. Settings → Your data imports an Obsidian vault (.zip), a Google Keep Takeout or a Day One journal. (Importing)
  3. Write. Choose New note, or press / in a note for headings, lists, tables, images and embeds. (Writing)
  4. Lock what's private. Lock any note with your Vault PIN, and add your fingerprint or face in Settings → Security.
  5. Put it on your phone. Open Papyra in your phone's browser and choose Add to Home Screen.
  6. Back it up. Settings → Your data downloads a password-protected backup file, and Settings → Git backup can push to a private GitHub repo. (Backups)

Stuck? Try Troubleshooting, or ask in #papyra-help on Discord.

Community

Papyra is a Lyfie project, made alongside luthor, the editor it is built on. It was vibe-coded: designed, tested and steered by a person, with AI coding assistants writing most of the code.

Star history

Star history chart for lyfie-org/papyra

For developers

Building from source, running the tests and the pull request flow are in CONTRIBUTING.md. The notes below explain how Papyra is put together.

How it works: files first, caches second

The filesystem is the source of truth. Every note is a .md file with YAML frontmatter, sitting in a folder you own. The Lucene index and the note list inside SQLite are disposable caches: Papyra rebuilds them from the files. SQLite also holds accounts, passkeys, sharing and settings, which are not rebuildable, so back up papyra.db with the rest of /data. Nothing about your notes depends on Papyra continuing to exist.

That means Syncthing, Dropbox, git or Obsidian can edit the vault behind the app's back. Papyra watches the folder, catches up, and surfaces sync-conflict files instead of choking on them.

Tech stack

Backend (/papyra.api)

Runtime .NET 10 Minimal APIs (C# 14)
Markdown & frontmatter Markdig 0.42 (UseYamlFrontMatter) + YamlDotNet 16.3; unknown frontmatter keys are round-tripped untouched
Full-text search Lucene.Net 4.8.0-beta00017 (+ Analysis.Common, QueryParser, Highlighter)
Cache / metadata EF Core 10 + SQLite (WAL): accounts, sharing and settings, plus a note mirror rebuilt from the .md files, which stay the authority for notes
Real-time FileSystemWatcher (one per tenant) + SignalR for metadata-only push
Live editing Hocuspocus + Yjs (papyra.collab), behind the API's /collab WebSocket proxy
Auth Cookie sessions, BCrypt passwords, TOTP, Fido2.AspNet passkeys, optional OIDC SSO
Git sync LibGit2Sharp: per-user credentials, never force-pushes
PDF export SkiaSharp (the journal book)
Docs OpenAPI + Scalar.AspNetCore

Local AI features (Whisper transcription, Tesseract OCR, Ollama embeddings and chat) are built but switched off. Their routes return 404 and stay out of OpenAPI until PAPYRA_AI_ENABLED is set.

Frontend (/papyra.web)

Framework React 19 / TypeScript 6 / Vite 8
Routing react-router-dom 7
Data fetching @tanstack/react-query 5: no Redux, no Zustand
Editor @lyfie/luthor 2.11 (our Lexical 0.40 wrapper)
Real-time @microsoft/signalr
Offline IndexedDB outbox + service worker; autosave, no save button

Website (/papyra.app)

Astro 7 static site with marketing pages, the docs pages, the rendered API reference, and a live in-browser demo built from papyra.web with a fake backend. Deployed to Cloudflare Pages from GitHub Actions.

The data volume: what lives where
data/
├── users/{userId}/
│   ├── notes/               # ← the source of truth: your .md files
│   │   └── journal/         # journal days, one file each (year/month/date.md)
│   ├── media/               # attachments referenced as ![[filename]]
│   ├── .trash/              # soft-deleted items (and media/{day}/ for unused attachments)
│   └── .papyra/             # UI state: snapshots/, order.json, categories.json, avatar
│       ├── vault-keys.json  # keys that seal locked notes — NOT disposable
│       ├── journal-templates/  # the journal's "Start from" pages
│       ├── media/           # per-attachment metadata, video posters, OCR/transcript text, thumbs/
│       └── archived-urls.txt  # pages the web archiver has saved (each URL once)
└── .papyra/
    ├── papyra.db            # SQLite: accounts, sharing, settings — NOT disposable
    ├── lucene-index/        # full-text index — rebuildable
    ├── media-jobs.json      # OCR / transcription work still to do (or given up on)
    └── keys/                # Data Protection key ring — NOT disposable

Papyra-owned state is always in a hidden .papyra/ directory, never inside the notes folder, so a sync client or file watcher never sees it churn.

Attachments and embed syntax

Attachments live flat in media/ and are written into notes the way Obsidian writes them, so a vault opens unchanged in either app:

You write You get
![[photo.png]] the picture at its natural size (up to the column)
![[photo.png|480]], ![[photo.png|480x320]] 480 px wide (and that tall); what dragging a handle saves
![[photo.png|A sunset|480]] with alt text
![[photo.png]] <!-- align:center --> <!-- caption:Our first night --> centred, captioned (the editor's toolbar writes these)
![[report.pdf#page=3]] a document as its desktop-style icon and name; Preview (or a double-click) opens it at page 3
![[q3-411e00.pdf|Q3 report]] the same, shown as "Q3 report" (Rename writes the alias; the file keeps its name)
![alt|300](https://…) <!-- align:right --> a web image, 300 px wide, aligned right
![[youtube:https://…|Talk|640x360]] <!-- align:left --> an embedded video with a caption, aligned left
![[iframe:https://…|800x600]] <!-- align:right --> an embedded page: Embed a link (or /embed) takes any link: a Google/Apple Maps place, a song, a video, a document or a page
![[card:https://…]] a link card (title, summary, picture); what a site that refuses to be framed becomes

In a table, escape the pipe: ![[photo.png\|200]]. A note is never rewritten just because it was opened; only what you change is saved.

Uploads are checked by their bytes, not their names (a web page renamed .png is stored as inert text), limited per kind (pictures 30 MB, GIFs 50 MB, audio and documents 100 MB, video 500 MB) and named so two image.pngs never collide. Pictures get small WebP thumbnails (cards and narrow columns never download camera originals); videos get a poster frame captured by the browser. Optional extras, all off unless configured:

Setting Turns on
Ocr:TessDataPath the words in pictures become searchable (Tesseract eng.traineddata)
Whisper:ModelPath WAV recordings are transcribed into their note (a Whisper model)
Media:HeifConvert thumbnails for iPhone HEIC photos via libheif's heif-convert (most browsers already send JPEG)

Text read out of attachments is kept beside them (.papyra/media/*.ocr.txt, *.transcript.txt), so rebuilding search never re-runs OCR, and a locked note's pictures are never searchable. Unused attachments move to the trash after a week and are purged with it; anything an old version of a note shows is kept.

License

GNU GPL v3.0. Free to use, change and share.

About

Star if Papyra keeps your notes yours! A self-hosted, Google Keep-style notes app where every note is a plain Markdown file on your disk. Live collaboration, passkeys, encrypted locked notes, full-text search and one-container Docker setup. Crafted with 💗 for people who want their notes without lock-in.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

164 stars

Watchers

1 watching

Forks

Releases

Sponsor this project

Packages

Used by

Contributors

Languages