Search...Search plugins and themes...
⌘K
Sign in
  • Get started
  • Download
  • Pricing
  • Enterprise
  • Account
  • Obsidian
  • Overview
  • Sync
  • Publish
  • Canvas
  • Mobile
  • Web Clipper
  • CLI
  • Learn
  • Help
  • Developers
  • Changelog
  • About
  • Roadmap
  • Blog
  • Resources
  • System status
  • License overview
  • Terms of service
  • Privacy policy
  • Security
  • Community
  • Plugins
  • Themes
  • Discord
  • Forum / 中文论坛
  • Merch store
  • Brand guidelines
Follow us
DiscordTwitterBlueskyThreadsMastodonYouTubeGitHub
© 2026 Obsidian

Find and replace in selection

dy-shdy-sh24k downloads

Find what you are looking for in the selected text and replace it with the specified text.

Add to Obsidian
  • Overview
  • Scorecard
  • Updates2

This plugin for Obsidian adds a "Find and replace in selection" command. This command performs a search in the selected text, and all found characters/words/text constructions will be replaced with others. The plugin can search for plain text or regular expressions.

How to configure

Assign a hotkey to "Find and replace in selection" command.

How to use

  • In the plugin settings, specify which text to search for (plain text or regular expression) and what to replace it with.
  • Just select the text (you can select the entire note) and press hotkey or call "Find and replace in selection" command. To quickly make a replacement in one line of text, you can simply put the cursor on this line and press the hotkey.

Examples

Remove bold highlighting from all text:

  • Text to find: "**"
  • Replace by: "" (empty)

Replace all H2 headers with H3 headers:

  • RegExp to find: "^## " (space at the end)
  • RegExp flags: "gm" (global, multiline)
  • Replace by: "### " (space at the end)

If you want to make all H1 become H2, all H2 become H3, H3 become H4, then you need to start with H3, then H2, then H1.

Remove all display text from embed links:

  • RegExp to find: "(?<!\\)\!\[(.*?)(?<!\\)\]\((.*?)(?<!\\)\)"
  • RegExp flags: "gm"
  • Replace by: "![]($2)"

As result, this: ![Description](URL) will become: ![](URL)

HealthGood
ReviewSatisfactory
About
Find and replace text only within a selected region or the current line using plain text or regular expressions. Replace all matches inside the selection to update headings, strip formatting, or transform embeds in-place.
EditingSearchFormatting
Details
Current version
1.0.2
Last updated
5 months ago
Created
6 years ago
Updates
2 releases
Downloads
24k
Compatible with
Obsidian 0.9.12+
Platforms
Desktop, Mobile
License
MIT
Report bugRequest featureReport plugin
Sponsor
Buy Me a Coffee
Author
dy-shdy-sh
github.com/dy-sh/
GitHubdy-sh
  1. Community
  2. Plugins
  3. Editing
  4. Find and replace in selection

Related plugins

Editing Toolbar

The Editing Toolbar is modified from cMenu, which provides more powerful customization settings and has many built-in editing commands to be a MS Word-like toolbar editing experience.

Sort and Permute lines

Sort and Permute lines in whole file or selection.

List Callouts

Create simple callouts in lists.

Linter

Format and style your notes. Linter can be used to format YAML tags, aliases, arrays, and metadata; footnotes; headings; spacing; math blocks; regular Markdown contents like list, italics, and bold styles; and more with the use of custom rule options.

LanguageTool Integration

Advanced grammar and spell checking, powered by LanguageTool.

Smart Connections

Find related notes and excerpts while writing. Your AI link building copilot displays relevant content in graph + list view. A local embedding model powers semantic search. Zero setup. No API key.

Meta Bind

Make your notes interactive with inline input fields, metadata displays, and buttons.

Tag Wrangler

Rename, merge, toggle, and search tags from the tag pane.

Quick Switcher++

Enhanced Quick Switcher, search open panels, and symbols.

Advanced Tables

Improved table navigation, formatting, and manipulation.