Hide an email address on a public webpage from automated scraping bots
Generate a unique scrambled font and mapping for each site or user
Encode and decode protected text using a simple command line helper
Add a demo HTML snippet that shows the scrambled font working in a browser
| bitilia/scrape-block | 0xallam/my-recipe | 0xhassaan/nn-from-scratch | |
|---|---|---|---|
| Stars | 0 | — | 0 |
| Language | Python | Python | Python |
| Last pushed | — | 2022-11-22 | — |
| Maintenance | — | Dormant | — |
| Setup difficulty | easy | moderate | moderate |
| Complexity | 2/5 | 2/5 | 4/5 |
| Audience | developer | general | developer |
Figures from each repo's GitHub metadata at analysis time.
Requires picking or supplying a source font file and installing Python requirements first.
This tool hides text such as email addresses from web scrapers by building a custom font that scrambles what appears in the page source while still showing the correct text to a human reading the page in a browser. A font normally maps each character to the shape it draws. This tool breaks that link on purpose. It creates a random scramble where no character maps to itself, then uses it in two places. First, it rewrites your real text, such as an email address, into gibberish that goes into your HTML. Second, it rebuilds the font so that when the browser reads that gibberish, it draws the shapes of the real characters instead. The result is that a visitor sees the correct email address on screen, while anyone reading the raw HTML or scraping the page only sees nonsense characters. Because the scramble is reversible, the tool can also decode the gibberish back into the original text when needed. Each time you run the tool it creates a fresh random mapping, so every user or website gets its own unique key rather than sharing one pattern that scrapers could learn. Running it is simple: install the requirements and run a Python script, either picking a font file through a popup window or pointing it at one directly. It outputs the new font in two formats, a mapping file that records how to encode and decode text, a small command line helper for converting text, and a demo HTML page showing it in action. The README is honest about the limits. Copy-paste and screen readers will only get the scrambled version, not the real text, so this should only be used for values like email addresses where that tradeoff is acceptable, and accessibility labels should be added separately. It also notes that a scraper who specifically targets this trick could download the font and reverse it, so this defends against ordinary automated scraping rather than a determined attacker focused on one particular site.
A tool that builds a custom scrambled font so email addresses look normal to visitors but appear as gibberish to web scrapers reading the page source.
Mainly Python. The stack also includes Python.
Setup difficulty is rated easy, with roughly 5min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
Don't trust strangers blindly. Verify against the repo.