Obsidian Publish note permalink options

Use case or problem

Currently links to an Obsidian Publish’s sites notes are based on the file structure and the name of the note. If you change that or the note’s title, then the link goes to a 404. These are fairly basic things to change to end up needlessly disrupting any links you may have shared to a particular note.

Proposed solution

Options to change permalink structures. My preferred method would be just a randomly generated code for each note, like “a8C89k”. So the resulting link, “obsidianpublishexample.com/a8C89k” would always link to the note it’s tied to regardless of any changes to the file structure or note. This could potentially replace the current way of linking or it could be added as an option alongside other potential link structures.

1 Like

I actually kind of like that solution. After all, we don’t really care what the URL itself looks like as long as it’s essentially human readable because we navigate within the structure via the interface links, anyway.

From an SEO and security perspective, it kind of bites because you want someone who gets a link to have what it actually does or is immediately readable and nothing looks quite as suspicious as an effectively anonymized the link. That’s a bit of a drawback, especially for sharing via social media mechanisms which don’t generate some sort of representative card.

It’s a complex problem to solve because both sides of the issue are important for different reasons.

Yes, this definitely is an issue. I only launched my Obsidian Publish site a few days ago, but have already managed to send share links here and there… and quickly discovered that I’m now unable to rename any of the shared pages, or to move them to a different folder… Sigh. :slightly_frowning_face:

Or I can do that, of course, but then need to create a manual redirect page at the original location, pointing to the new location, which really sucks from a productivity standpoint.

There should be a better way, right? On the web, it should work just as smoothly as it does in local Obsidian – you rename a file or move it to a different folder, yet all the links get automatically adjusted and everything works just as before. That’s currently not the case on our Obsidian Publish sites if their pages are shared externally, unfortunately.

Technically, there is a better way.

If you make an alias entry in your front matter which looks like “old path/old name”, it will resolve that original link location to the new page.

The problem online is that you don’t control the URLs that other people hold so you can’t necessarily automatically redirect. There’s a fine argument to suggest that moving a page that has already been shared once with publish should recognize that fact and automatically insert the new alias entry by default, but I haven’t seen anyone make that argument yet.

I think it is a good idea but…

Obsidian Publish has permalinks, am I missing something?

Also aliases can be used for redirection:

1 Like

Thank you, that does appear to be the solution!

However, at least for now, as an Obsidian newbie, I have no clue how to employ it. I will study the help file links you posted, though, so many thanks for that.

(Right now, I have no clue what “properties” are, how to add them, etc. Somehow, I would expect such redirects to work “automatically”, like they do in local Obsidian or, say, in WordPress on the web, but it appears to be a much more complicated and manual process in Obsidian Publish. Anyway, great to hear that it is possible to achieve this.)

My suggestion is to set a structure to automatically be used for all notes on publish. It is possible to generate a random string yourself and specify it in the frontmatter for each note you publish, or create some script to do that for you, but that’s quite inconvenient and not really a nice solution, so this is my feature request.

1 Like

Automation is definitely the way to go. On my WordPress sites, permalinks are created automatically, but I have the option to customize them, if so desired. That’s what I’d like to have in Obsidian Publish as well.

(9 days later after I first posted in this thread, I still haven’t figured out how to handle permalinks in Obsidian. You see, real life gets in the way: I’ve got loads of work to do, so no time to study Obsidian help files – for now. Obsidian is supposed to be a work tool for me, making my work easier, instead of adding to my workload, which already is totally overwhelming for me, so for now, I haven’t got to studying the topics of properties and permalinks in Obsidian yet. I’ll get to it one day, because permalinks on the web are important for me, but right now, due to time pressure, I lack the time to find out how to set up permalinks manually in Obsidian…)

1 Like

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