Image Link Updater
pendingby Andy Lai
Automatically updates markdown image links when image files are renamed or moved in the vault.
Image Link Updater (Obsidian Plugin)
Update every image link in your vault automatically.
- 🔄 Drag / Rename an image in Obsidian File Explorer → every
or![[…]]reference is rewritten to the new vault‑root path. - 📋 Paste an image from the clipboard → stored in your attachment folder and inserted as Markdown
(instead of the default wiki link). - ✂️ Cut & Paste files with context menu → move single or multiple files and automatically update all image links.
- 🗃 Fallback for OS moves (delete + create events) – if you move images outside Obsidian, links are still fixed by filename.
Why use it?
- Stop broken screenshots – keep your docs intact when you reorganise folders.
- Markdown‑first workflow – pasting images no longer forces wiki links.
- Works with spaces – matches both raw names (
My image.png) and URI‑encoded names (My%20image.png). - Efficient file management – cut and paste multiple files at once with automatic link updates.
Features in detail
| Action | Before | After |
|---|---|---|
| Move / Rename image |  |  |
| Paste image | Default Obsidian: ![[Pasted image …]] | Plugin:  |
| Cut & Paste files | Manual drag with broken links | Right-click cut/paste with auto-updated links |
| Move outside Obsidian |  (broken) |  |
Rewrites vault‑wide; wiki links keep spaces un‑encoded.
Cut & Paste Files
Move files efficiently with automatic link updates:
Single File
- Right-click on any file → Cut
- Navigate to destination folder
- Right-click on folder → Paste
Multiple Files
- Select multiple files (Shift + Click or Ctrl + Click)
- Right-click on any selected file → Cut (X items)
- Right-click on destination folder → Paste X files
Features:
- Automatically handles name conflicts (adds numbers like
file 1.png) - Updates all image links throughout your vault
- Works with both image and non-image files
- Shows notifications for success/failure
- Can paste to folders or vault root
Installation
Community Plugins (recommended)
Once approved:
Settings → Community plugins → Browse- Search "Image Link Updater" and click Install
- Enable the plugin
Manual
- Download the latest release assets:
manifest.json,main.js, (optionalstyles.css) - Create a folder
<your vault>/.obsidian/plugins/image-link-updater/ - Place the files inside, matching this layout:
image-link-updater/
├─ manifest.json # "main": "main.js"
└─ main.js
- Enable the plugin in Settings → Community plugins
Building from source
# 1. clone
git clone https://github.com/andy51002000/obsidian-image-link-updater.git
cd obsidian-image-link-updater
# 2. install deps
npm install
# 3. compile (main.js generated in dist/ or root depending on manifest)
npm run build
Copy the compiled files (manifest.json, main.js) into your vault's plugins folder.
How it works
Automatic Link Updates
When you move or rename image files, the plugin:
- Detects the change via Obsidian's vault events
- Searches all markdown files for references to the old path
- Rewrites links to use vault-root absolute paths
- Handles both Markdown
and Wiki![[path]]formats
Clipboard Image Handling
When you paste an image:
- Intercepts the paste event
- Saves the image to your configured attachment folder
- Inserts a Markdown link with URI-encoded path
- Ensures proper leading slash for vault-root paths
Cut & Paste with Link Updates
When you cut and paste files:
- Stores the selected files in memory
- Moves files to the destination folder on paste
- Automatically updates all image links if moving image files
- Handles multiple files in batch operations
Configuration
The plugin respects your Obsidian settings:
- Attachment folder: Uses your configured attachment folder path
- File naming: Follows Obsidian's naming conventions
- Link format: Generates Markdown links for pasted images
Troubleshooting
Links not updating after move?
- Check the developer console (Ctrl+Shift+I / Cmd+Option+I) for
[ImageLinkUpdater]messages - Ensure the file is recognized as an image (png, jpg, jpeg, gif, bmp, svg, webp)
Cut option not appearing?
- Make sure the plugin is enabled in Settings → Community plugins
- Try rebuilding the plugin if installed manually
- Check that you're right-clicking on files (not folders) for the Cut option
Paste not working?
- Ensure you've cut files first (look for notification confirming cut)
- Right-click on a folder or in empty space to paste
- Check console for any error messages
License
Image Link Updater is released under the GNU Affero General Public License v3.0 or later.
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.