Title Shortener

unlisted

by marumimamori

Shorten overly long note paths while preserving full titles as aliases.

Updated 10d agoGPL-3.0
View on GitHub

Title Shortener by Maru

Keep long Obsidian note titles without letting their physical file paths become unsafe for Windows, Cryptomator, or synchronization tools.

Current version: 0.1.0


Features

  • Checks the complete absolute path on desktop, with a vault-relative fallback where unavailable
  • Watches new notes, manual renames, note moves, and folder moves
  • Shortens only when the configured path threshold is exceeded
  • Preserves the original human-readable title as an Obsidian alias
  • Appends alias history or keeps only the latest plugin-generated alias
  • Leaves manual aliases, tags, and unrelated frontmatter untouched
  • Uses readable shortened titles with configurable numeric or hash suffixes
  • Tries optional numeric suffixes from 1 through 9 before collision hashes
  • Detects filename collisions and never overwrites an existing note
  • Supports excluded folders, safety margins, and per-setting reset controls
  • Previews long paths before an optional bulk migration
  • Uses Obsidian's FileManager APIs so link updates follow Obsidian's settings
  • Works locally without telemetry or network access

Install With BRAT

  1. Install Obsidian42 - BRAT from Obsidian's Community Plugins.
  2. Open the command palette.
  3. Run BRAT: Add a beta plugin for testing.
  4. Enter https://github.com/marumimamori/title-shortener.
  5. Let BRAT install the plugin, then enable Title Shortener under Settings > Community plugins.

Notice

  • This plugin was vibe-coded, tested continuously in a development vault, and adapted to fit its intended workflow.
  • It is currently distributed through BRAT for beta testing.
  • Test bulk changes on a backup or disposable vault before applying them to an important collection.
  • Please report bugs with reproducible steps through GitHub Issues.

Requirements

  • Obsidian 1.4.0 or newer
  • Desktop Obsidian for complete absolute-path measurement
  • Mobile and non-local adapters are supported with vault-relative path measurement

How It Works

Title Shortener compares each Markdown note's path against the configured maximum minus its safety margin. The defaults are a maximum of 240 characters and a safety margin of 40, producing an effective threshold of 200 characters.

When a path exceeds that threshold, the plugin keeps as much readable title text as fits, adds the configured separator and suffix, writes the original title to aliases, and renames the note through Obsidian.

Example with the default three-dot separator and numbers-first mode enabled:

A very long human-readable note title...1.md

If the vault and parent folders already consume the available budget, shortening the filename cannot solve the problem. The plugin leaves the note unchanged and reports it as blocked instead of performing a misleading rename.

Alias History

Keep one generated alias replaces only aliases previously created by Title Shortener. Append alias history keeps each unique original title after later long renames. Manual aliases and aliases from other plugins are preserved in either mode.

Generated filename suffixes are omitted from aliases. If the desired alias already exists in the note, it is not written again.

Cryptomator And Windows

Cryptomator expands encrypted names internally, and Windows applications or synchronization tools may impose stricter limits than the underlying filesystem. The plugin cannot predict every encrypted or provider-specific path, so its configurable safety margin is intentionally conservative.

Short vault locations and mount points still help. Title Shortener reduces path-length risk but cannot guarantee compatibility with every storage provider, virtual filesystem, or synchronization tool.

Commands

  • Check current note path length
  • Shorten current note now
  • Scan vault for long paths

The vault scan previews proposed names and separately lists notes whose parent folders are already too long.

Beta Notes

Title Shortener is still in beta. BRAT is the recommended installation path while automatic rename behavior is tested across more vault layouts, operating systems, and Cryptomator configurations.

No telemetry is included.

License

Title Shortener is free software licensed under GPL-3.0-or-later.

If you distribute a modified version, keep the license and attribution notices and provide the corresponding source code.

Development

Install dependencies:

npm install

Build:

npm run build

For a manual test installation, copy manifest.json, main.js, and styles.css into:

<Vault>/.obsidian/plugins/title-shortener/

Then reload Obsidian and enable Title Shortener.

For plugin developers

Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.