How to Keep a Structured Markdown Journal Using Vimwiki

Table of Contents ๐
Journaling has long been an effective way to reflect, track tasks, and document ideas or conversations. But if youโre a terminal-based user who enjoys the minimalism of Vim, Markdown, and data ownership โ youโre in luck. In this post, youโll learn how to set up a lightweight, private, and highly productive journaling system using vimwiki, all in plain text files synced via Nextcloud.
Whether youโre logging calls, capturing thoughts, or tracking your daily wins, this setup will help you keep everything organized โ without giving up control to a third-party app.
Changelog
| Date | Change |
|---|---|
| 2025-06-19 | Restructured article to move quick access methods into Step 3 for better visibility. |
| 2025-06-18 | Major revision: Added to-do lists, improved configuration, and corrected template/alias usage. |
| 2025-06-17 | Initial version of this article. |
Why Use Vimwiki for Journaling?
vimwiki is a Vim plugin that transforms your editor into a personal wiki. Itโs lightweight, fast, and supports:
- Daily journal entries (diary mode)
- Linked notes for projects or topics
- To-do lists and simple task tracking
- Markdown syntax for compatibility
- Full offline access โ works with Nextcloud or any sync service
If youโre already storing notes in Markdown, this is a perfect upgrade.
Step 1: Install vimwiki
Using vim-plug (or your plugin manager of choice), add this to your .vimrc:
Plug 'vimwiki/vimwiki'Then launch Vim and run:
:PlugInstallIf youโre not using vim-plug, check the installation instructions here.
Step 2: Configure Vimwiki to Use Markdown
In your ~/.vimrc, configure vimwiki to store files in a Markdown format inside your Nextcloud folder. This configuration is cleaner and easier to maintain.
" Vimwiki Configuration
let g:vimwiki_list = [{
\ 'path': '~/Nextcloud/Notes/wiki/', " Path to your wiki's root folder
\ 'syntax': 'markdown', " Use Markdown syntax
\ 'ext': '.md' " Use .md as the file extension
\}]
" Ensures that created links include the .md extension for better compatibility
let g:vimwiki_markdown_link_ext = 1
" Automatically creates an index of all diary entries
let g:vimwiki_auto_diary_index = 1Create the necessary folders manually if they donโt exist:
mkdir -p ~/Nextcloud/Notes/wiki/diaryStep 3: Creating and Accessing Your Daily Journal
The core of your journaling workflow is creating or opening the note for the current day. Here are the best ways to do it.
The Basic Command
The fundamental command to create or open todayโs journal entry is:
:VimwikiMakeDiaryNoteThis command will create a file like ~/Nextcloud/Notes/wiki/diary/2025-06-21.md if it doesnโt exist, and open it otherwise.
Recommended Methods for Quick Access
While the basic command works, typing it every time is impractical. For a fast and efficient workflow, use these shortcuts instead.
Method 1: From Inside Vim (The Fastest Way)
vimwiki comes with a built-in keyboard shortcut that is perfect for daily use. While in Vimโs normal mode, simply press:
<leader>w<leader>w
This is the most efficient way to open your journal when you are already working in Vim. The <leader> key is typically the backslash (\) by default.
Method 2: From Your Terminal
For moments when you want to jump directly into your journal from the command line, a shell alias is the perfect tool. Add this line to your .bashrc or .zshrc file:
alias journal='vim -c "VimwikiMakeDiaryNote"'After reloading your shell, you can now simply type journal in your terminal. This will launch Vim and immediately open todayโs diary entry, applying your template if itโs a new day.
Example Entry
Regardless of which method you use to open it, your daily note will look something like this:
# 2025-06-21
## 09:02 โ Call with Sarah
Discussed the project milestones. Need to follow up next Tuesday.
## 13:45 โ Idea
Use `jrnl` CLI for quick journal entries via terminal.
## 20:15 โ Reflection
Today was productive. Really enjoying the new Vim-based workflow.Step 4: Create and Follow Internal Links
Link to another page in your wiki using vimwikiโs native syntax:
[[Project Alpha]]Pressing Enter on this link will create and navigate to Project Alpha.md.
For universal compatibility with other Markdown editors (like Obsidian or QOwnNotes), you can use a standard Markdown link. vimwiki will still follow it if you press Enter.
[Project Alpha](Project%20Alpha.md)The key difference is that [[Project Alpha]] is deeply integrated into vimwikiโs features (like backlinking), while the standard link is more portable across different applications.
Step 5: Create a Diary Template (Optional)
Add a default template for your daily entries. Itโs best practice to store the template in your wikiโs root directory.
Create the template file:
~/Nextcloud/Notes/wiki/template.mdImportant:
vimwikiusesstrftimeformat codes, not{{placeholders}}.# %Y-%m-%d ## โ๏ธ Calls ## ๐ก Ideas ## โ Tasks ## ๐ Notes ## ๐ ReflectionAdd this line to your
.vimrc. Using a relative path makes your config more robust.let g:vimwiki_diary_template = 'template.md'
Every new diary file created with :VimwikiMakeDiaryNote (or the shortcuts) will now use this layout.
Bonus Tips
- Manage To-Do Lists:
vimwikihas excellent support for task lists. Useg<Space>on a list item in Vim to cycle through states.- [ ] An open task - [.] A task in progress - [X] A completed task - Quick Navigation: After following a link, press
Ctrl-Oto go back to the previous location andCtrl-Ito go forward. - Diary Index: Use
:VimwikiDiaryIndexto open thediary/index.mdโ a central view of all your entries. - Search: Use
:VimwikiSearch KEYWORDto find entries across your entire wiki. - Syncing: Sync your
wiki/folder with Nextcloud, and view or edit it from mobile apps like Markor (Android) or 1Writer (iOS).
Summary
With vimwiki, you can build a minimal yet powerful journaling system:
โ Fully Markdown-compatible โ Terminal- and Vim-native โ Works offline and syncs via Nextcloud โ Extendable with links, to-do lists, templates, and more
No bloated app, no subscription, no cloud lock-in.
๐| โน๏ธ LOOKING FOR MORE VIM TIPS? |
In a future post, weโll explore how to integrate |





