This guide looks at how you can set up and manage your templates in Obsidian. Using Obsidian templates can make your life easier and potentially more productive.
This guide will only cover the template module provided in the core Obsidian application. Community plugins are not covered in this guide.
Obsidian core template plugin
The template module can be switched on or off by doing the following steps
- Click on the settings icon at the bottom left of the Obsidian application window.
- Select core plugins from the options menu on the left of the settings pop-up window.
- On the right side of the setting window next to the template is a radio switch
- Click on the radio switch to turn it on or off.
Now that the template is switched on. You now need to create a folder in your Obsidian fault to store the templates you will create in the future.
Obsidian Template settings
Once you have created a folder in your Obsidian vault to store the templates you will create in the future, we can now look at how you can change the template settings in your vault.
To access the template setting screen, click on the settings icon at the bottom left of Obsidian from the settings menu and select templates listed under the core plugin.
At the top of the template settings screen, you will see a blank field giving an example. In that field, type in the name of the folder you created for your templates.
The following two fields specify the date and time format should you use the time and date placeholders in any of the templates you have created.
The settings screen includes a link to the formatting reference sheet, and I suggest you look there for full details on what options are available to you.
I have looked at the vault I created for my how-to make an Obsidian vault guide, and the default date format for dates is YYYY-MM-DD. You might think this is a bit of a strange format?
The reason for using this format is that dates will be sorted in the correct order when using ascending or descending order, and arguably I shouldn’t have changed the format in my vault, but I did it for a couple of good reasons. I had already changed the sort order for my main vault to sort by the date that the note was created, and secondly, I was going to use the date for my journal initially, and DD-MMMM-YYYY seemed to be the most readable format.
Managing templates in Obsidian
In this section, we will look at the lifecycle of a template within Obsidian.
How to create a template in Obsidian
A template is created the same way as any other note in Obsidian. Once the Template has been created, you should give the Template a meaningful name. For example, the Template I made for my daily journal is called Template_DailyJournal. You are probably wondering why I prefixed the name with Template? I did it so I could easily distinguish my Template set-up noted from my other notes when I have my folders extended in file view.
Your Template should contain the content you want to pre-populate notes created from that Template and can be made up of text, Markdown and placeholders.
I need to give you quick overview of what I mean by placeholders in this guide, and besides, they are pretty cool. The date and time placeholders, when placed in a template, tells Obsidian to insert the system date or time where the placeholder is.
The image of the date placeholder is taken from my daily journal template. I’m writing this guide on 11 February 2023. So when I created my daily journal earlier, the placeholder was replaced by today’s date of 11 February 2023. Which saves me having to type in the dates every day.
Once you have finished creating your Template, drag it into the template folder you created earlier.
How to update a template in Obsidian
To update a template, extend the folder you created for your templates and open the file containing your Template. Make the changes you want to make, and then close down the file. Your Template can be made up of any combination of text, Markdown and placeholders.
How to delete an Obsidian template
To update a template, extend the folder you created for your templates and select the file you wish to delete and press the delete key on your keyboard. Be very careful. No warning prompt is displayed!
How to use your templates in Obsidian
Now that we have some templates to use, we should look at how we actually use the templates you have created.
You can add the Template by opening the Obsidian command palette by pressing CTRL/CMD and P keys. At the same time, opening the palette menu, start typing in template select Templates: insert Template. Obsidian will then list the templates stored in your template folder and select the Template you wish to insert.
Other core plugins, such as the Obsidian daily notes core plugin, also use templates.
Conclusion
In this guide, we have looked at how we can turn on and off the Obsidian core template plugin, how to manage the templates you create, and finally, how to use your templates.
Obsidian templates are very functional and useful components allowing you to automate some of your routine processes within Obsidian.
Can I recommend our introduction to Obsidian canvas?