(Re) Introduce a way to set how many spaces a tab keypress is converted to

Right now, when the tab key is pressed it is possible to configure Obsidian to enter either one tab char or 4 spaces.

Some users likely prefer to have a way to specify the number of spaces a tab key-press is converted to.

It is important to note that Obsidian does NOT support proper delimiter based indentation (that dictates a variable number of spaces for proper indentation).
Right now, indenting with anything different than 1 tab or 4 spaces will be broken.

20 Likes

Not directly related, but if someone is looking for a way to convert indention to 4 spaces as a workaround until this is implemented, I have documented a way to do it in Indenting with 2 spaces in 1.8.x - #3 by spasche

Chiming in to say that indenting with 2 spaces (via tab and via > in vim mode) in markdown files has been my personal standard for markdown notes in obsidian and is compatible with my configs in doom emacs and sublime text. Re-introducing this option would be very useful for me. Thank you.

2 Likes

This is huge for me too. As someone who works with his files in raw formats frequently, having to always use 4 spaces for indentation in those contexts is a huge hassle.

1 Like

I’m confused. It seems like in previous versions I could indent with 2 spaces, and now I realise that on mobile it’s indenting with 4, and it seems it’s also doing that on desktop. I read this post which linked here saying this was a deliberate change. Is this change documented somewhere? I’m struggling to understand the situation. It seems like this option has been removed, and there is a feature request by a forum moderator to bring it back? Or have I misunderstood something?

On a persona level, this is quite an issue for me, I use my notes in other tools, and I’m realising that now I need to go back and try to fix all my corrupted data since Obsidian made this change without my awareness.

1 Like

same here. this is quite disruptive to my workflow. right now I’ve been indenting with a macro, but that feels a bit awkward and hard to use in other devices.

One problem caused by the lack of this feature is that for codes that indent with 2 spaces, it’s very inconvenient to edit them in obsidian.

2 Likes

I can hear for the same reason. I was always able to indecent with 2 spaces (within a code block) and now it is rendering with 4.

I also would love to get 2 back (or the option to change).

I would love to have this feature as well.

I’ve been experimenting with using Claude Code in an Obsidian vault, and so far it has been a really powerful combination. This gives me even more reason, in addition to the several reasons I already had, to want the experience of editing my markdown files across multiple tools to be smooth and seamless.

A huge part of the benefit of Obsidian is that the underlying files are in a standard format that many tools can work with, and having settings like being able to configure how indentation is handled is key for Obsidian to be able to work with other tools effectively.

Right now most of the tools I’m using are flexible on indentation, and Obsidian sticks out as one of the few with the least flexibility/configurability in this area.

I would like this feature as well.
What is little inconsistent it that: when adding properties to one note, it uses 2 spaces in the YAML indentation. I would like to have consistency: either use 2 spaces in both YAML properties and markdown lists, or use 4 spaces in both.