Nanopad is a lightweight Notepad replacement designed to provide a simple yet efficient text editing experience on Windows. Built using pure Win32 C++, it offers a modern take on classic Windows text editors with a focus on portability and minimal runtime dependencies.
Key Features:
Dark/Light Mode: Automatically follows the system theme, with manual override options.
Font Customization: Choose from various fonts, sizes, and styles via the native ChooseFont dialog.
Find & Replace: Supports case-sensitive search and replace operations.
Printing: Includes headers, footers, and page numbers for professional output.
Encoding Detection: Handles UTF-8, UTF-16, and ANSI files seamlessly.
Per-Monitor DPI Scaling: Adapts to different screen resolutions for optimal display quality.
Portable Settings: All configurations are stored in an INI file alongside the executable.
Audience & Benefit:
Ideal for users seeking a lightweight, portable text editor without the need for installation or runtime dependencies. Nanopad is perfect for developers and everyday users who value simplicity, efficiency, and seamless integration with Windows. Its compact design ensures quick launches and minimal resource usage while maintaining essential functionality.
Installable via winget, Nanopad combines modern features with classic simplicity, making it a reliable choice for those who want more from their text editor without the bloat.
README
Nanopad
A simple, portable Win32 text editor in the spirit of classic Windows Notepad.
Developed with the assistance of AI tooling.
See CHANGELOG.md for release-to-release user-facing changes.
Read more about my experiences with AI and this project on my blog.
Features
File I/O — Open, Save, Save As with encoding detection (UTF-8, UTF-8 BOM, UTF-16 LE/BE, ANSI)
Dark / Light mode — Follows Windows system theme automatically, with manual override; fully themed title bar, menu bar, scrollbars, and status bar
Font selection — ChooseFont dialog, DPI-aware, persisted across sessions (default: Consolas 11pt)
Zoom — Ctrl+mouse wheel, View menu (Zoom In/Out, Restore Default Zoom), or Ctrl+Plus / Ctrl+Minus / Ctrl+0
Find & Replace — Find Next/Previous, Match Case, Replace All
Print — With headers, footers, and page numbers
Status bar — Line/column, character count, encoding, line endings
Word wrap — Toggle via Format menu
Drag & drop — Drop files onto the window to open
External file reload — Reloads when the open file changes on disk; prompts first if you have unsaved edits
Crash & shutdown recovery — Autosaves unsaved text and offers to restore it after a crash, power loss, or a Windows Update restart; registers for automatic restart so Windows relaunches Nanopad after an update reboot
Go To Line — Ctrl+G
Large file support — Memory-mapped I/O for files >1MB
Push/PR to master — Builds Debug + Release automatically via GitHub Actions
Tag a release — git tag v1.0.0 && git push --tags triggers a release build that creates a GitHub Release with a zip containing the exe, README, CHANGELOG, and SHA256 checksum
Version is stamped automatically from the git tag into version.h — no manual version bumps needed
System Requirements
Windows 10 1809+ for full feature set (dark mode, themed menus/scrollbars, DPI scaling)
Windows 10 1607+ runs with graceful degradation (dark mode features silently disabled)
All dark mode APIs are loaded dynamically — no hard dependencies on specific Windows versions
Keyboard Shortcuts
Shortcut
Action
Ctrl+N
New
Ctrl+O
Open
Ctrl+S
Save
Ctrl+Shift+S
Save As
Ctrl+P
Print
Ctrl+Z
Undo
Ctrl+X/C/V
Cut/Copy/Paste
Ctrl+A
Select All
Ctrl+F
Find
F3 / Shift+F3
Find Next / Previous
Ctrl+H
Replace
Ctrl+G
Go To Line
Ctrl+Plus / Ctrl+Minus
Zoom In / Out
Ctrl+0
Restore Default Zoom
Ctrl+Shift+W
Close Window
Settings
Stored in nanopad.ini next to the executable (portable — no registry writes):
Font face, size, weight, italic, charset, quality
Theme mode (System / Light / Dark)
Window position, size, and state (normal/maximized)
Original Notepad debugger value (for safe restore after Replace Notepad)
Unsaved text is autosaved to a transient per-instance nanopad-recovery-.recovery file next to the executable. It is written on shutdown and periodically while editing, then deleted on a clean exit; if it survives (crash, power loss, or update restart) Nanopad restores it automatically on the next launch -- no prompt. Each running instance uses its own file, and when several sessions are recovered each is reopened in its own window.
System Integration
Add to Open With
Help → Add to Open With registers Nanopad in the Windows right-click "Open with" menu for common text file extensions (.inf, .ini, .log, .ps1, .psd1, .psm1, .scp, .txt, .wtx). Uses HKCU — no admin required. Toggle off to unregister.
Explorer Context Menu
Help → Windows Integration → Add "Edit with Nanopad" to Explorer adds a right-click context menu entry for all file types. Uses HKCU — no admin required. On Windows 11, appears in "Show more options". Toggle off to unregister.
Replace Notepad
Help → Replace Notepad redirects all notepad.exe launches system-wide to Nanopad via Image File Execution Options. Requires administrator privileges (UAC prompt). The original IFEO state is saved to nanopad.ini and can be fully restored by unchecking the option.