π― Easy-to-use tool for text replacements across multiple Word documents at the same time. Handles hyperlinks, text boxes, headers, footers safely. Previews changes with diff context and processes multiple files at once. Real-time match counter shows results as you type. Perfect for bulk document updates. Download exe, no installation needed! Made for efficiency.β‘
- Go to exe and download
WordTextReplacer.exe. - Double-click to run. No installation required!
- Add your Word documents and start replacing text.
Option 2: Download executable and add it to your context menu (recommended for the fastest approach)
- Go to exe and download
WordTextReplacer.exe. - Save it to your preferred path. no installation required!
- Go to c_m_e and download
add_word_text_replacer_to_your_context_menu.reg. - Adapt the .reg file by inserting the path where you saved
WordTextReplacer.exe(step 2) in line 8 and 15. (Optional: Edit the icon in line 4 & 11 and the text of the context menu line 5 & 12.) - Run the .reg file and confirm that you want to add it to registry editor. Afterwards, you can delete the .reg file. This is a one-time effort only.
- Right-click on any .doc/.docx/.docm file and click on your context menu entry to run the script. (Optional: Add more files in which you want to run the search and replace workflow.)
- Start replacing text.
It's just one Python file β download it from src and play around with it. :)
| Feature | Standard Replace | Advanced Replace |
|---|---|---|
| Speed | β‘ Very fast | π§ Comprehensive |
| Main content | β Paragraphs & tables | β Paragraphs & tables |
| Text boxes | β | β All types |
| Headers & footers | β | β |
| Footnotes & endnotes | β | β |
| Form fields | β | β |
| Formatting preserved? | β | β |
| Hyperlinks | β Replaces text and preserves links. | |
| Regex support | β Python regex syntax | β (Word's native engine) |
| Whole word match | β | β |
| Case sensitive | β | β |
Large batch operations (100+ files)/Simple text in paragraphs and tables/No hyperlinks in replacement text/Speed is important/Regex patterns needed
- Remember: If your file has "special content" (text boxes, headers, footers, footnotes, endnotes, form fields, and hyperlinks), but you are not going to replace any of this text, you can still use the very fast Standard Replace. It won't break any of your "special content".
If you are going to replace "special content", use Advanced Replace as it will work for both standard content, such as paragraphs and tables, and "special content". It is just slower than the Standard Replace as it uses Word COM automation instead of python-docx.
Sometimes you just want to replace a text snippet which is not present in any "special content" and you want to do that as fast as possible. Therefore, I added the very fast Standard Replace (which will maintain formatting, don't worry!).
- π Real-time match counter: See match count update live as you type β no need to run a preview first.
- π Preview with diff context: See what will be changed, including surrounding text context for each match.
- π Hyperlink check: Analyze documents for hyperlinks before deciding which replace method to use.
- π€ Whole word match: Option to match whole words only.
- π£ Regex support: Full Python regex support for Standard Replace/Preview.
- π Non-breaking space support: Use
_nbsp_or Shift+Space. - π Invisible character handling: Automatically strips soft hyphens and zero-width characters that Word inserts β so your searches always match what you see.
- π Batch processing: Handle multiple documents at once, including whole folder trees via "Add folder".
- πΎ Backup creation: Optional, per-file backups that are never overwritten by later runs.
- β©οΈ Restore backups: Roll selected files back to their backed-up state with one click.
- β¨οΈ Keyboard shortcuts: Efficient workflow.
This video, with a slightly outdated UI, shows the tool in action.
If you don't want to hear me talking for too long, just jump to 3:30.
- Legal documents: Update contract terms across multiple files.
- Technical documentation: Replace product names or versions.
- Marketing materials: Update company information or branding.
- Academic papers: Standardize terminology or citations.
- Corporate communications: Update contact information or policies.
| Shortcut | Action |
|---|---|
F5 |
Preview changes |
Ctrl+Enter |
Standard Replace |
Ctrl+Shift+Enter |
Standard Replace and automatically close the application afterwards |
Shift+Enter |
Advanced Replace |
Ctrl+O |
Add more files |
Shift+Space |
Insert non-breaking space |
Ctrl+1/2 |
Focus search/replace boxes |
Tab |
Switch between search & replace boxes |
Delete |
Remove selected files (when file list is focused) |
- OS: Windows 7/8/10/11
- Software: Microsoft Word (for Advanced Replace features)
- Installation: None required for executable version
WordTextReplacer/
βββ _legacy/ # legacy version (v1.1)
βββ c_m_e/ # .reg file
βββ doc/ # User Manual
βββ exe/ # .exe file
βββ src/ # Source Code (single .py file)
Contributions are welcome! I am not an experienced developer. If you have ideas/upgrades/improvements, I am happy to see your code!
- Fork the repository.
- Create a feature branch.
- Make your changes.
- Submit a pull request.
Licensed under a Source-Available License (Apache 2.0 + No Selling clause). β See LICENSE for details.
The tool is free and I am happy with sharing it with whoever wants to use it. If you want, you can buy me a coffee. βπ And connect with me!
- Built with Python and tkinter for the GUI.
- Word COM automation (pywin32) for advanced document operations.
- python-docx for fast document processing.
- I used AI to create this tool. :)
β¬π¦β¬ Forza Inter! β¬π¦β¬
Made with enthusiasm for efficient document processing.