How to Create a Website From Markdown Files

Updated

Markdown is plain text with a few conventions for headings, lists, links and images. It is readable as it is, works in any editor, and converts cleanly to HTML — which makes it a natural source for a website.

This guide takes a folder of Markdown files and publishes it as a website with Sentilis, without a build step or hosting to manage.

1. Organize the folder

Group files by what they become on your site:

my-content/
├── bio/
│   └── en.md                 ← your about page
├── press/
│   ├── hello-world.md        ← a post
│   └── guide/
│       ├── index.md          ← a documentation page…
│       ├── install.md        ← …and its sections
│       └── attachments/
│           └── cover.png
└── market/
    └── one-hour-call.md      ← a service people can buy
  • press/ holds posts, articles and documentation.
  • bio/ holds a profile page, one file per language.
  • market/ holds products and services, with checkout included.

There are also prime/ for monthly memberships and gallery/ for visual work.

2. Give each file a settings block

A short block of settings at the top — the frontmatter — tells Sentilis how to show the file:

---
name: Hello, world
category: Notes
status: published
---

# Hello, world

My first page, written in plain Markdown.

Every field is optional: without name, the file name is used. The rest of the file is your content, written in normal Markdown.

3. Add images the right way

Local images need a folder: put the page in its own folder with an attachments/ folder next to it, and reference images from there.

![Setup diagram](./attachments/diagram.png "How the pieces fit")

Remote images from https:// URLs work anywhere, including in single-file pages.

4. Publish

Install the Sentilis CLI, log in with your profile token and sync the folder:

npm i -g @sentilis/cli
sentilis auth login <your-token>
sentilis sync ./my-content

Run sentilis sync again after every change. Pages keep their URL as long as their slug stays the same.

5. Automate it (optional)

If my-content/ lives in a Git repository, the same commands can run in CI on every push to your main branch. Your site then updates whenever you merge a change, with the Markdown files as the only source of truth.

Which editor?

Any editor that saves .md files works. Obsidian has a Sentilis plugin that publishes from a right-click; Typora and VS Code save Markdown files you can publish as they are. Apps that keep notes in their own library can export them as Markdown first.

Turn your Markdown files into a website →

Keep reading

Guides →

Your Markdown is already your content. Now give it a home on the web.

Publish your Markdown →