Dynamic Link to Daily Note with Today's Date

Things I have tried

What I’m trying to do

I have a file called Dashboard that I use to link to other notes, some sort of a workspace with links to things I am working on. I want to include a link to the current daily note.

I have tried things like [[Daily Notes/{{DATE:[[YYYY-MM-DD}}]] but that does not work (because I do not know what I am doing).

Is there a way to do this? the format of my daily note is simple: YYYY-MM-DD as in 2021-10-02.

1 Like

How you want to create a dynamic link?
With a permanent “formula” inside your Dashboard?
Templater plugin have “dynamic commands” like <%+ tp.date.now() %> but I think they don’t work properly inside “[[ ]]”.
Dataview plugin can solve you problem using inline queries like these:

`=link(dateformat(date(today), "yyyy-MM-dd"))`
`="[[" + dateformat(date(today), "yyyy-MM-dd") + "]]"`

Yes, I need a dynamic link in my Dashboard that changes everyday automatically to the Daily Note for today. I will check Dataview… I have it installed. I was hoping that Obsidian would have a native way to create these dynamic links… Thanks!

Hopefully other forum friends can comment if they have other ideas.

You can use the Templates command to insert today’s date on your dashboard. You would need to update the link every day, but it’s a couple keystokes.

Command+P, search for “Templates: Insert today’s date”.

For me it’s hot-keyed as Command+Shift+D. I don’t remember if that is my hotkey or the default.

This seems to work as you said just fine. I only need now a button to switch from Edit to Preview in my Dashboard and will have a solution for now. Dateview is awesome!

="[[" + dateformat(date(today), "yyyy-MM-dd") + "|DAILY NOTE ]]"

It’s possible to create a button ‘rendered’ in Preview mode, not in the inverse.

Of course one solution was using the Buttons plugin, which has an available command to go to the daily note. It also offers previous day note but that one does not work. See image for the 2 solutions, one with the inline Dataview code, the other below with the Button command.

1 Like

For “Yesterday” (using Dataview):

`="[[" + dateformat(date(today) - dur(1day), "yyyy-MM-dd") + "|Yesterday]]"`

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.