Open-source project
papermark/papermark avatar
papermark/papermark

Papermark: what self-hosting it actually costs you

Papermark is the open-source DocSend alternative and secure data rooms with built-in analytics and custom domains.

9,451 stars1,445 forksTypeScriptNOASSERTION

At a glance

What is it?
Tracing the documented setup path, analytics, storage, and billing each rest on a separate hosted service, and two of them need a local process started by hand. Papermark works as a DocSend alternative, but the installation steps understate the bill.
Who is it for?
Choose Papermark if you need document links on your own domain and can commit to running Postgres, object storage, Tinybird, and QStash without a managed platform behind you. Pass on it if page-level engagement reporting is the reason you are leaving DocSend, because that piece is still filed as upcoming.
Can I use it commercially?
Check first. The repository uses a licence we do not classify automatically, so read its LICENSE file before any commercial use.
Is it still maintained?
Yes. The repository last received commits 87 days ago.
What is it written in?
Mainly TypeScript, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 23, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • papermark/papermark9,451 ★ · +244
Star history
Repository2026-09-222026-11-23
papermark/papermark9.2k9.5k

244 Stars in the last 62 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

Document tracking is published to Tinybird, not Postgres

Papermark splits its data in two. Relational records go through Prisma into PostgreSQL, and the analytics event stream goes somewhere else entirely: Tinybird. The .env.example file marks that split plainly, with TINYBIRD_TOKEN described as the variable needed to publish and read event data. Nothing in that file points the token at Postgres or at the application database, so leaving it blank does not degrade analytics, it removes them. The dependency list shows the same seam from the code side, with Tinybird named as the analytics entry in the tech stack and a zod-bird package for validating those events. The practical consequence for anyone evaluating the product is that the interesting half of the tracking story lives outside the database you provision, and outside the backup policy you write for that database.

The tb push glob only ships endpoints beginning with get_

Getting that second service running takes its own CLI, its own Python environment, and a push step whose glob is narrower than the directory it points at. From lib/tinybird you push the data sources, then the endpoints:

sh
tb push datasources/*
tb push endpoints/get_*

The second pattern matches only files whose names start with get_, so an endpoint in that directory without that prefix stays on your machine and never becomes queryable. The README does not enumerate the endpoint files, so you cannot tell from the documentation which ones those are. Dependency management is its own step as well, run inside a pipenv shell with a pkgx-specific wrapper for climbing back to the repo root:

sh
pipenv update tinybird-cli

Page-by-page analytics is still filed as upcoming

The analytics bullet offers two things in one line: document tracking, and page-by-page analytics marked as coming soon. Only the first exists today, and that gap decides what you can learn from a shared link. Document-level tracking tells you that a recipient opened the file and roughly when. It does not tell you which pages held their attention, which ones they skipped, or where they returned to later, because that data is not collected yet. No release note, milestone, or issue reference gives a date for it, and the repository description claims secure data rooms while the README feature list never mentions data rooms at all. For a team weighing this against DocSend, the fair reading is that you get the tracking half of the feature now and wait on the half that explains what happened inside the document.

The Node floor disagrees between the README and package.json

The prerequisites list says Node.js version >= 18.17.0. The engines field in package.json says >=24. Both statements are in the repository, and the JSON is the stricter of the two, so the version the prose tells you to install is not the version the project declares. The surrounding scripts are ordinary Next.js ones, dev, build, start, and lint, with nothing that reads as version specific, which leaves the older number looking stale rather than load bearing. Install on 18 or 20 and you get an engine complaint pointing at a field you were never told about, at the moment you are trying to diagnose something else. Set 24 or newer before you start and the discrepancy costs you nothing.

Choosing the S3 transport means naming a distribution host yourself

NEXT_PUBLIC_UPLOAD_TRANSPORT takes two values, and the default written into .env.example is vercel. Switch it to s3 and one variable becomes load bearing: NEXT_PRIVATE_UPLOAD_DISTRIBUTION_HOST, described in that same file as the distribution host without protocol, used in the next.config.mjs configuration. The comment offers three shapes for it, a Vercel blob host, a CloudFront distribution, and an S3 bucket address, and the value has to match the transport you picked.

npm install already runs prisma generate, and the build runs migrations

The documented path from a clean machine is six commands, and the schema client generates itself as a postinstall step of npm install:

shell
git clone https://github.com/mfts/papermark.git
cd papermark
shell
npm install
shell
cp .env.example .env
shell
npm run dev:prisma
shell
npm run dev

Two details deserve attention. The clone URL written in the README is the mfts path, while the repository itself sits under the papermark organization, so confirm which one resolves before you debug anything downstream. And dev:prisma is not a convenience wrapper: it expands to npx prisma generate && npx prisma migrate deploy, and the vercel-build script runs prisma migrate deploy && next build. Schema changes therefore apply when you run dev:prisma in development and on every vercel-build in production, with no dry run to inspect first. The two database variables in .env.example, POSTGRES_PRISMA_URL and POSTGRES_PRISMA_URL_NON_POOLING, are blank, and the only database guidance is a single prerequisite line naming a PostgreSQL database.

Billing, mail, and background jobs each want their own local process

Payments, transactional mail, and queued work do not start with npm run dev. Each has a separate script, and two of them need a long-running process you launch yourself:

code
"stripe:webhook": "pkgx stripe listen --forward-to localhost:3000/api/stripe/webhook"
"email": "email dev --dir ./components/emails --port 3001"
"trigger:v4:dev": "npx trigger.dev@4 dev"

The Stripe script forwards billing events to localhost:3000/api/stripe/webhook, so with the CLI not listening there, checkout completes at Stripe and your application never hears about it. Mail gets its own dev server on port 3001 reading templates out of ./components/emails. Queued and background work needs Upstash QStash, and .env.example asks for a token plus the current and next signing keys, while the trigger scripts target a separate hosted API at https://api.trigger.dev with its own TRIGGER_SECRET_KEY. That is three more command line tools to install and keep running on the machine: pkgx, npx trigger.dev@4, and the email binary.

Two Next.js routers and an ee tree, with no architecture note

At the top level you find app/ and pages/ side by side, plus middleware.ts at the root and a next.config.mjs that reads the storage host you configured. Two router trees in one repository means requests can enter through either, and nothing in the repository states which is canonical or where the boundary sits, so any change you make has to be traced across both. Next to them sit ee/ and CLA.md, which nothing explains, alongside locales/ for translation and .agents/, .cursor/, and skills-lock.json for tooling. The license deserves attention before you build on this: GitHub reports no SPDX identifier for the repository, while the README links straight to a LICENSE file at the top of the page. Those two facts together mean a badge or a metadata field will not tell you what you are allowed to ship, so read the file yourself and map the app/, pages/, and ee/ split before your first change.

Editorial conclusion

Choose Papermark if you need document links on your own domain and can commit to running Postgres, object storage, Tinybird, and QStash without a managed platform behind you. Pass on it if page-level engagement reporting is the reason you are leaving DocSend, because that piece is still filed as upcoming. Before either, read the LICENSE file directly and confirm your runtime matches the Node >=24 declared in package.json.

Frequently asked questions

What exactly is papermark?

It is an open-source document sharing product positioned as the open-source alternative to DocSend, with shareable links, custom domains and branding, and document tracking. It is written in TypeScript on Next.js with Prisma and PostgreSQL, and its home page is papermark.com.

is papermark open source

Yes. The repository ships its own README, Prisma schema, and build scripts, and the repository description calls it the open-source DocSend alternative. GitHub reports no SPDX identifier for it, so read the LICENSE file at the top of the repository to see the actual terms before you redistribute it.

is papermark free

The README publishes no pricing, no free tier, and no plan limits. Stripe appears in the dependency list with a webhook script for billing events, so payment handling is part of the product. Running the code yourself is a separate question from what a hosted account costs.

papermark vs docsend

Papermark presents itself as the open-source DocSend alternative and lists shareable links, custom branding, document tracking, and self-hosting among its features. Its repository description also claims secure data rooms with built-in analytics and custom domains, a term the README feature list never mentions.

How to use papermark?

Clone the repository, copy .env.example to .env, run npm install, npm run dev:prisma, and npm run dev, then open http://localhost:3000. The stated prerequisites are Node.js version >= 18.17.0, a PostgreSQL database, AWS S3 or Vercel Blob storage, and Resend for sending emails.

what does papermark do

It shares documents over custom links, puts them on your own domain with your own branding, and records that a recipient opened them. Page-by-page analytics is described as coming soon, so behavior inside the document is not measured yet. Analytics events are published to Tinybird rather than stored in the application database.

Official sources

  1. Issues
  2. papermark/papermark on GitHub
  3. Project website
  4. README
  5. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/papermark-papermark.svg)](https://hysenlabs.com/projects/papermark-papermark)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/papermark-papermark.svg)](https://hysenlabs.com/projects/papermark-papermark)

Was this useful?