A GNOME Shell extension that extracts text from any area of your screen using OCR (Optical Character Recognition).
- 📸 Native Screenshot UI: Uses GNOME's built-in screenshot selection
- 🔍 Automatic OCR: Extracts text and copies to clipboard automatically
- 🌍 Multi-language Support: 14+ OCR languages supported
- ⌨️ Customizable Shortcut: Default
Super+Shift+T - 💾 Optional Screenshot Storage: Save or auto-delete after OCR
- 🔔 Notifications: Optional success/error notifications
- Press Super+Shift+T
- Select screen area using native GNOME screenshot UI
- Text is extracted via OCR and automatically copied to clipboard
- Done! Paste anywhere with
Ctrl+V
- GNOME Shell 48 or 49
- Tesseract OCR
- Python 3 with
pytesseractandPillow
git clone https://github.com/Aditya190803/TextExtractor.git
cd TextExtractor
chmod +x install.sh
./install.shThe installation script will:
- Install Tesseract OCR and Python dependencies automatically on Debian/Ubuntu, Fedora, and Arch
- Install the extension to
~/.local/share/gnome-shell/extensions/ - Install the OCR helper script automatically and make it available to GNOME Shell
- Compile GSettings schemas
If your distribution is not supported by the installer, install tesseract, python3, python3-pip, and zip manually first, then run ./install.sh again.
# On X11: Press Alt+F2, type 'r', press Enter
# On Wayland: Log out and log back in
gnome-extensions enable text-extractor@aditya190803Or use GNOME Extensions app / Extension Manager.
Open preferences via:
- GNOME Extensions app → Text Extractor → ⚙️
- Or:
gnome-extensions prefs text-extractor@aditya190803
| Setting | Description | Default |
|---|---|---|
| Shortcut | Keyboard shortcut to trigger | Super+Shift+T |
| OCR Language | Language for text recognition | English (eng) |
| Show Notifications | Display result notifications | ✓ Enabled |
| Save Screenshots | Keep screenshots after OCR | ✓ Enabled |
Screenshots are saved to ~/Pictures/Screenshots/TextExtractor/
| Language | Code | Language | Code |
|---|---|---|---|
| English | eng |
Russian | rus |
| German | deu |
Japanese | jpn |
| French | fra |
Chinese (Simplified) | chi_sim |
| Spanish | spa |
Chinese (Traditional) | chi_tra |
| Italian | ita |
Korean | kor |
| Portuguese | por |
Arabic | ara |
| Dutch | nld |
Hindi | hin |
Install additional languages:
# Ubuntu/Debian
sudo apt install tesseract-ocr-<code>
# Fedora
sudo dnf install tesseract-langpack-<code>
# Arch
sudo pacman -S tesseract-data-<code>- Ensure image has clear, readable text
- Try selecting a larger area
- Check OCR language setting
# Check if installed
ls ~/.local/share/gnome-shell/extensions/text-extractor@aditya190803/
# Check logs
journalctl -f -o cat /usr/bin/gnome-shellReset to default in extension preferences.
./uninstall.shOr manually:
gnome-extensions disable text-extractor@aditya190803
rm -rf ~/.local/share/gnome-shell/extensions/text-extractor@aditya190803
rm ~/.local/bin/text-extractor-ocrTextExtractor/
├── build/ # Extension source files
│ ├── extension.js # Main extension logic
│ ├── prefs.js # Preferences UI
│ ├── ocr_helper.py # Python OCR script (installed to ~/.local/bin)
│ ├── stylesheet.css # Styles
│ ├── metadata.json # Extension metadata
│ └── schemas/ # GSettings schema
├── install.sh # Installation script
├── uninstall.sh # Uninstallation script
├── LICENSE
└── README.md
Note: The ocr_helper.py script is installed as a system-wide dependency at ~/.local/bin/text-extractor-ocr and is not bundled with the extension package, following EGO Review Guidelines.
GNU General Public License v3.0
- Tesseract OCR
- pytesseract
- GNOME Shell Extension API
Aditya - GitHub
⭐ Star this repo if you find it useful!