Build Medium
NOT REALLYreplaces $5/mosaves $60/yrback to the verdict
Not a Medium clone: the readership is the product and no code produces it. This is the consolation done right: your archive imported to your own domain, a typographic reading experience, syndication to Medium with canonical pointing home so the audience still finds you, and a reader list you own.
Before step 1
Everything below is assumed from the first step. Tick each one when you actually have it, not when you plan to.
- installfree
Why Everything in this build runs on it: the server, the scripts, the tests.
Get it Download the LTS installer from nodejs.org, or install with your package manager (brew install node, or nvm install 22). Restart the terminal afterwards. open ↗
Verify
node --version prints v22 or higher - installfree
Why Every step below is a command you type or a file you edit.
Get it VS Code (code.visualstudio.com), Cursor or Zed. Open a folder for the project and use the editor's built-in terminal. open ↗
Verify
You can open a folder and run a command in its terminal - installfree
Why History for your code, and the way most hosts deploy.
Get it Install from git-scm.com or with your package manager, then run git init in the project folder once it exists. open ↗
Verify
git --version prints a version - have readyfree
Why Phase 1 imports every past post with its date.
Get it Medium > Settings > Security and apps > Download your information. You receive a zip of HTML files by email.
- accountfree
Why Deploy on push.
Get it Cloudflare Pages or Netlify. open ↗
- accountroughly $10 a year, or free on an existing domain
Why Your archive at your address.
Get it Register at Cloudflare Registrar, Porkbun or Namecheap, or use a subdomain of one you already own. You add one DNS record in the deploy phase. open ↗
- API keyfree
Why Phase 3 syndicates with canonical set. Medium's API is limited; the import-a-story tool is the fallback.
Get it Medium > Settings > Security and apps > Integration tokens. If unavailable, use medium.com/p/import with your post URL.
Environment variables
These go in a .env file the app reads at startup. The pack's .env.example is this table as a file · copy it, never commit the filled-in version.
| Variable | Needed | Example | Where the value comes from |
|---|---|---|---|
SITE_URL | required | https://yourname.com | Canonical base. |
MEDIUM_TOKENsecret | optional | ... | Integration token for syndication. Empty means use the import tool by hand. |
The build, in order
Your archive
Every past post on your domain with its original date.
- terminal
npm create astro@latest archive -- --template minimal --typescript strict --install --git
- terminal
npm install turndown@7 node scripts/import-medium.mjs ~/Downloads/medium-export/posts
done when · tick each as it passesReading experience
Syndication with canonical
Publish here first, mirror to Medium with canonical home.
The reverse order leaves Medium canonical; do not do it.
done when · tick each as it passesReaders you own
A signup list stored locally, exported into a sender when ready.
done when · tick each as it passesDeploy
Operate the signup endpointproduct builder
Monitor and back up the one server you run.
done when · tick each as it passes
That is the whole plan for Medium. What it deliberately does not cover is below · check the gaps before you call it a replacement.
- The recommendation feed, claps, publications, Partner Program earnings: that is the network.
- the readership that finds you without marketing
- the Partner Program payouts
- publications and their editors
- claps, follows and the recommendation algorithm
- Syndicate to Substack Notes or dev.to with the same rule
Need the files? The project pack on the verdict page hands your agent the whole brief · more publishing.