GO KALI FREE

theHarvester

Information Gathering

Beginnerlow risk

Learn how to use theHarvester in Kali Linux: gather emails, subdomains, employee names, open ports, and banners from public sources with a step-by-step first scan, API keys, and worked examples for authorized OSINT recon.

Installation

sudo apt install theharvester

Basic Syntax

theHarvester -d <domain> -b <source> [options]

Quick Facts

Category
OSINT / Passive Reconnaissance
Platform
Linux / macOS / Windows
Type
Passive Information Gathering
Difficulty
Beginner-Friendly
Common Usage
Email & Subdomain Discovery
Language
Python 3
License
GPL
Risk Level
Low (Passive)

Tool Overview

theHarvester is a free, open-source Python OSINT tool from the laramies/theHarvester project on GitHub, and it comes pre-installed on Kali Linux. You use it by supplying a domain and one or more sources — for example, `theHarvester -d example.com -b crtsh,certspotter` — then reviewing the returned emails, subdomains, IPs, URLs, and ASNs. Current releases are roughly versions 4.6–4.9.

A beginner's first-run loop is simple: verify the Kali installation with `theHarvester -h`, or install it with `sudo apt install theharvester` if needed. Run a no-API-key scan with crtsh and certspotter, then read the Emails, Subdomains/Hosts, IPs, URLs, and ASNs sections and note each source tag. Next, add the needed credentials to `api-keys.yaml`, rerun with API-backed sources, and save a report with `-f`. Finally, copy the discovered subdomains into a clean list, verify which ones resolve or respond, and hand the live hosts to httpx or Nmap for the next authorized inventory step.

For an illustrative first scan, run `theHarvester -d example.com -b crtsh,certspotter -l 500 -f first-scan`. In Subdomains/Hosts, `[crtsh] api.example.com` means the crtsh source found a certificate-derived hostname; `[crtsh] mail.example.com` is a second candidate, not proof of a live mail service. Resolve or validate both before passing them onward. These certificate sources may leave Emails and IPs empty. In a broader follow-up, the Emails line `[bing] admin@example.com` means Bing returned that address from indexed data, not that the mailbox is valid; the IPs line `[dnsdumpster] 93.184.216.34` means DNSDumpster linked that IP to the domain. The bracketed label provides source attribution. Check scope, deduplicate results, use `-v` or `-n` to verify hosts, and open `first-scan.html` to review the saved report.

By default, theHarvester is passive: it queries third-party sources and never touches the target's servers. Adding `-s` enables active DNS brute-force, so use it only for a domain you own or have written authorization to test. The Google source is deprecated in newer releases; start with crtsh and certspotter instead. If a search returns nothing, check for source rate limits, retry later, and try other sources. Consider `-s` only when active testing is in scope, not as a routine workaround.

theHarvester is a Python-based OSINT tool designed for passive reconnaissance. It gathers publicly available information about a target domain including email addresses, subdomains, employee names, open ports, and service banners from multiple public sources without directly interacting with the target infrastructure.

The tool queries search engines (Google, Bing, Yahoo, DuckDuckGo), certificate transparency logs (crt.sh), DNS databases (DNSDumpster, PassiveTotal), and specialized APIs (Shodan, Hunter, SecurityTrails) to compile a comprehensive intelligence report. This passive approach makes theHarvester ideal for early-stage reconnaissance where minimal detection risk is required.

theHarvester is essential for penetration testers, red teamers, bug bounty hunters, and security auditors who need to map an organization's external attack surface before launching active scanning. The discovered emails feed into phishing campaigns, subdomains reveal forgotten infrastructure, and employee names enable social engineering attacks.

Quick Reference Commands

Verified quick-reference commands for theHarvester
CommandPurpose
uv run theHarvester -d <authorized-domain> -b crtsh,certspotterUse passive certificate sources.
uv run theHarvester -d <authorized-domain> -b subdomainsRun the current subdomain source category.
uv run theHarvester -d <authorized-domain> -b emails,urls,certspotterCollect email, URL, and certificate-source results.
uv run theHarvester -d <authorized-domain> -b crtsh,certspotter -f <report-basename>Save results under the specified basename.
uv run theHarvester -d <authorized-domain> -b emails,ips,urls --no-hosts -f <report-basename>Collect non-host result categories and write reports.
theHarvester README

Common Commands

theHarvester -d example.com -b googleGoogle search — Gather emails and subdomains using Google search engine
theHarvester -d example.com -b bingBing search — Discover emails and subdomains via Bing search engine
theHarvester -d example.com -b allAll sources — Run enumeration across all supported public engines and APIs
theHarvester -d example.com -b linkedinLinkedIn search — Find employee names and professional profiles
theHarvester -d example.com -b bing -l 200Limit results — Restrict Bing search to first 200 results
theHarvester -d example.com -b google -f report.htmlHTML output — Save results to an HTML report file
theHarvester -d example.com -b all -sDNS brute-force — Enable DNS brute-force subdomain enumeration
theHarvester -d example.com -b crtshCertificate transparency — Query crt.sh for subdomains via CT logs
theHarvester -d example.com -b shodanShodan search — Query Shodan for open ports and banners (requires API key)
theHarvester -d example.com -b hunterHunter search — Query Hunter.io for corporate email patterns (requires API key)
theHarvester -d example.com -b securitytrailsSecurityTrails — Query SecurityTrails for historical DNS and subdomain data (requires API key)
theHarvester -d example.com -b dnsdumpsterDNSDumpster — Query DNSDumpster for DNS reconnaissance and subdomain discovery
theHarvester -d example.com -b bing -l 500 -f report.html -sCombined scan — Bing search with 500 limit, DNS brute-force, and HTML output
theHarvester -d example.com -b all -s -f output.html -nFull scan — All sources with DNS brute-force, HTML output, and DNS resolution
theHarvester -d example.com -b google -cVirtual hosts — Discover virtual hosts hosting the target domain
theHarvester -d example.com -b duckduckgoDuckDuckGo search — Gather emails and subdomains without an API key
theHarvester -d example.com -b certspotterCertSpotter — Discover subdomains from certificate transparency logs, no API key needed
theHarvester -d example.com -b hackertargetHackertarget — Query Hackertarget for subdomains and DNS data
theHarvester -d example.com -b otxAlienVault OTX — Query OTX threat intelligence for subdomains and IPs
theHarvester -d example.com -b githubGitHub search — Find emails and code references in public repositories (requires API key)
theHarvester -d example.com -b crtsh -e 8.8.8.8Custom DNS server — Resolve discovered subdomains using Google DNS (8.8.8.8)

Step-by-Step Guide

  1. 1Open a Kali terminal and run `theHarvester -h` to verify the installation, using `sudo apt install theharvester` first if the command is missing
  2. 2Confirm that the domain is yours or covered by written authorization, keeping example.com as the illustrative target in this guide
  3. 3Run the first no-key passive scan with `theHarvester -d example.com -b crtsh,certspotter -l 500`
  4. 4Read the Emails, Subdomains/Hosts, IPs, URLs, and ASNs sections, using tags such as `[crtsh]` to identify the source of every lead
  5. 5Run a no-key email sweep with `theHarvester -d example.com -b bing,duckduckgo -l 500` and note the email patterns it returns
  6. 6Only with written permission, enable active DNS brute-force by running `theHarvester -d example.com -b crtsh,certspotter -s`
  7. 7From a source checkout's repository root, run `nano api-keys.yaml` and enter the required keys for any Shodan, Hunter, SecurityTrails, VirusTotal, or GitHub sources you intend to use, then rerun the email sweep with `theHarvester -d example.com -b bing,duckduckgo,hunter,linkedin -l 500`
  8. 8Save an HTML report with `theHarvester -d example.com -b crtsh,certspotter -l 500 -f first-scan`, then review the generated `first-scan.html` file
  9. 9Verify candidate subdomains with the DNS-oriented options in `theHarvester -d example.com -b crtsh,certspotter -v -n`, and retain only names that resolve within scope
  10. 10Put the authorized, resolving names in `live-subdomains.txt`, probe web services with `httpx -l live-subdomains.txt -silent`, and inventory those hostnames with Nmap by running `nmap -iL live-subdomains.txt`

Warnings

Use Cases

Bug Bounty Reconnaissance

Map the target's external attack surface before active scanning. Discover subdomains, email patterns, and exposed services to identify potential vulnerabilities.

External Attack Surface Mapping

Identify all public-facing assets including subdomains, email infrastructure, and open services for comprehensive security assessments.

Corporate OSINT Investigation

Gather intelligence on organizational structure, employee emails, and technology stack from public sources for penetration testing engagements.

Employee Discovery

Extract employee names and email patterns from LinkedIn and search engines to build credential lists for brute-force or phishing attacks.

Subdomain Enumeration

Discover forgotten subdomains, staging environments, and internal applications exposed to the internet through certificate transparency logs.

Phishing Campaign Preparation

Build targeted email lists and understand corporate email naming patterns for realistic phishing simulations during authorized engagements.

Key Features

Comparison

theHarvester vs Amass vs Subfinder — Recon Feature Matrix

FeaturetheHarvesterAmassSubfinder
Primary FocusEmails + subdomains + OSINTAttack-surface mappingSubdomains only
Email DiscoveryYes (core feature)NoNo
Subdomain Sources20+ mixed sources40+ (deepest)40+ passive
Open Ports / BannersYes (via Shodan)LimitedNo
Employee NamesYes (search engines)NoNo
SpeedFastSlow (thorough)Very fast
Best ForBroad OSINT footprintEnterprise mappingQuick subdomain lists

Passive vs Active Reconnaissance — Where theHarvester Fits

FeaturetheHarvesterDNSenumNmap
ApproachPassive (third-party)Active (queries target DNS)Active (probes hosts)
Detection RiskVery lowMediumHigh
Touches Target?No (queries public sources)Yes (DNS servers)Yes (ports/services)
Data ReturnedEmails, subdomains, namesDNS records, subdomainsPorts, services, OS
Recon PhaseFirst (footprinting)Second (DNS mapping)Third (scanning)

theHarvester Source Types — When to Use Which

FeatureSearch EnginesCertificate LogsSecurity APIs
Examplesgoogle, bing, yahoo, duckduckgocrtsh, certspottershodan, hunter, securitytrails
Best ForEmails + employee namesReliable subdomainsPorts, patterns, history
API Key NeededNoNoYes (most)
Rate-Limit RiskHigh (429/CAPTCHA)LowDepends on tier
ReliabilityVariableHighHigh

Best Practices

Common Errors

theHarvester: command not found
Install with sudo apt update && sudo apt install theharvester. If you cloned the repo, run it from the source directory with python3 theHarvester.py -d <domain> -b all.
ModuleNotFoundError: No module named 'aiohttp' (or similar)
Reinstall dependencies: pip3 install -r requirements.txt from the repo, or reinstall the package. Use a virtualenv (python3 -m venv) to avoid system package conflicts.
No emails or subdomains found
Query multiple sources with -b all, and add API-backed sources (Shodan, Hunter, SecurityTrails). Enable DNS brute-force with -s for subdomains not indexed anywhere.
[!] Missing API key in api-keys.yaml
Add keys to ~/.theHarvester/api-keys.yaml (or the repo's api-keys.yaml). Free tiers work but are rate-limited. Skip these sources with search-engine-only sources if you have no key.
Google/Bing returns 429 or blocks queries
Slow down, reduce the result limit with -l, rotate sources, or route through a proxy. Prefer certificate-transparency (crtsh) and API sources that do not CAPTCHA.
SSL: CERTIFICATE_VERIFY_FAILED when querying a source
Update CA certs (sudo apt install --reinstall ca-certificates) and the certifi package (pip3 install -U certifi). Check the system clock — a wrong date breaks TLS validation.
Read timed out / connection errors mid-scan
Retry, or query sources individually to isolate the failing one. Transient source outages are common — rerun later or exclude the problem source.
Discovered emails or subdomains are stale/invalid
Validate before use: verify subdomains resolve (dig/httpx) and confirm email deliverability separately. Treat OSINT results as leads, not confirmed facts.
api-keys.yaml YAML parse error
Use two-space indentation and quote values with special characters. Validate the file with a YAML linter, and follow the exact template shipped in the repo.
-l limit ignored / results truncated unexpectedly
Combine multiple sources rather than pushing one source's limit. Use -b all and dedupe the aggregated output for broader coverage.
DNS brute-force (-s) finds nothing
Complement -s with dedicated brute-force tools (DNSenum -f with SecLists, or Amass) and passive sources like crt.sh and Subfinder for fuller coverage.
HTML/XML report file is empty or not written
Confirm the scan returned data first, use an absolute path you can write to, and check disk permissions. The -f file is only populated when results exist.

People Also Ask

What is the difference between theHarvester and Subfinder?

theHarvester is a broad OSINT collector that gathers emails, employee names, subdomains, ports, and banners from search engines and public APIs. Subfinder is a specialized subdomain-discovery tool that pulls from far more certificate transparency and DNS sources. Use theHarvester for people-and-email intelligence; use Subfinder for exhaustive subdomain enumeration.

Which theHarvester sources need API keys?

Free sources that need no key include crtsh (certificate transparency), duckduckgo, bing, otx, rapiddns, and threatminer. Sources that require an API key include shodan, hunter, securitytrails, censys, and github. Add keys to the api-keys.yaml file; most providers offer a limited free tier.

Can theHarvester find emails without brute-force?

Yes. theHarvester discovers emails passively through search engines (Google, Bing), LinkedIn, and Hunter.io without any DNS brute-force. The -s flag enables DNS brute-force for subdomains, not emails. For email-only discovery, omit -s and use -b google,bing,hunter.

How do I export theHarvester results?

Use the -f flag to write output to a file: theHarvester -d example.com -b all -f report. Modern versions produce an HTML report plus a JSON file. For CSV, parse the JSON output. Store one report per engagement with a dated filename and sanitize before sharing.

Is theHarvester still maintained in 2027?

Yes. theHarvester is actively maintained by Christian Martorella (laramies) and contributors on GitHub, with regular releases that add new data sources and fix broken scrapers. Keep it updated with apt upgrade, pipx upgrade, or pulling the latest Docker image for reliable results.

How is theHarvester different from Recon-ng?

theHarvester focuses on email and subdomain discovery from search engines and public APIs with a simple single-command interface. Recon-ng is a full-featured reconnaissance framework with modules for multiple OSINT tasks, database storage, and reporting. Use theHarvester for quick email discovery; Recon-ng for structured multi-phase campaigns.

Related Tools

Subfinder

Information Gathering

Learn how to use Subfinder in this beginner tutorial, from installing ProjectDiscovery's passive subdomain tool to running and reading your first authorised scan. Add API keys for wider coverage, save clean results, and chain Subfinder into httpx to validate live web hosts before further testing.

Amass

Information Gathering

OWASP Amass is the industry-standard in-depth network mapping and attack surface discovery tool. It uses active and passive techniques, scraping 20+ public data feeds, DNS enumeration, and certificate transparency logs to discover subdomains, IP addresses, and ASN data — making it essential for penetration testing, bug bounty hunting, and enterprise security assessments.

DNSenum

Information Gathering

DNSenum is a multithreaded Perl script for DNS enumeration that discovers DNS records, attempts zone transfers, brute-forces subdomains, and performs reverse lookups. It is a foundational reconnaissance tool in Kali Linux for mapping a target domain's DNS infrastructure.

Nmap

Information Gathering

Learn how to use Nmap, the free open-source network scanner: run your first port scan, discover live hosts, detect services and operating systems, and check for vulnerabilities with NSE scripts — a beginner tutorial for Kali Linux.

Whois

Information Gathering

Whois is a query and response protocol used for querying databases that store registered users of Internet resources. It provides information about domain registration, ownership, registrar details, name servers, and expiration dates for any domain or IP address block.

dig

Information Gathering

dig (domain information groper) is a flexible tool for interrogating DNS name servers. It performs DNS lookups and displays the answers that are returned from the name server(s).

Related Cybersecurity Guides

OSINT · Intermediate

Reconnaissance Workflow: Complete Information Gathering Process

Learn a complete reconnaissance workflow combining OSINT, DNS enumeration, subdomain discovery, and active scanning for comprehensive target profiling.

Tools · Beginner

theHarvester Guide: Email and Subdomain Gathering

Learn theHarvester for passive reconnaissance including email harvesting, subdomain discovery, IP enumeration, and virtual host identification.

OSINT · Intermediate

Email Enumeration Techniques: Corporate Email Discovery for OSINT

Master email enumeration techniques using theHarvester, search engines, and certificate transparency logs. Learn corporate email pattern discovery, employee identification, and attack surface mapping.

OSINT · Intermediate

Passive Reconnaissance Workflow: Stealthy OSINT Gathering

Master passive reconnaissance techniques for stealthy information gathering. Learn to use OSINT tools without direct target interaction for penetration testing and security assessments.

Frequently Asked Questions

What is TheHarvester?

theHarvester is a passive OSINT tool for gathering email addresses, subdomains, employee names, open ports, and banners from public sources. It queries search engines, certificate transparency logs, DNS databases, and security APIs to compile intelligence reports without directly interacting with the target.

What does TheHarvester do?

theHarvester gathers publicly available information about a target domain including email addresses, subdomains, employee names, open ports, and service banners. It queries search engines (Google, Bing), certificate transparency logs (crt.sh), and APIs (Shodan, Hunter) to compile intelligence for penetration testing and security assessments.

How do I use TheHarvester?

Basic usage: theHarvester -d example.com -b google. For comprehensive results: theHarvester -d example.com -b all -s -f report.html. The -d flag specifies the domain, -b selects sources (google, bing, all, crtsh, shodan), -s enables DNS brute-force, and -f saves results to a file.

How do I install TheHarvester in Kali Linux?

theHarvester comes pre-installed in Kali Linux. If missing, install with: sudo apt install theharvester. Update to the latest version: sudo apt update && sudo apt install theharvester. For the latest development version, clone from GitHub: git clone https://github.com/laramies/theHarvester.git.

How do I install TheHarvester in Ubuntu?

Install on Ubuntu/Debian: sudo apt install theharvester. For the latest version, install via pip: pip3 install theHarvester. Alternatively, clone from GitHub: git clone https://github.com/laramies/theHarvester.git && cd theHarvester && pip3 install -r requirements.txt.

How do I update TheHarvester?

Update via apt: sudo apt update && sudo apt install theharvester. For pip installations: pip3 install --upgrade theHarvester. For GitHub installations: cd theHarvester && git pull && pip3 install -r requirements.txt. Check version with: theHarvester --version.

What sources does TheHarvester support?

theHarvester supports 20+ sources: Search engines (google, bing, yahoo, duckduckgo, yandex), certificate transparency (crtsh, certspotter), DNS databases (dnsdumpster, passivetotal, virustotal, threatminer), APIs (shodan, hunter, securitytrails, github), and social (linkedin). Use -b all to query all sources.

Can TheHarvester find emails?

Yes, email discovery is theHarvester's primary feature. It searches Google, Bing, LinkedIn, and Hunter for corporate email addresses. Use -b google for basic email discovery, -b linkedin for employee names, and -b hunter for corporate email patterns. Enable multiple sources for maximum coverage.

Can TheHarvester find subdomains?

Yes, theHarvester discovers subdomains through search engine indexing, certificate transparency logs (crtsh), and DNS brute-force (-s flag). Search engines index subdomains in results; crt.sh logs SSL certificates; DNS brute-force guesses common names (api, dev, staging). Use -b all -s for maximum subdomain coverage.

Is TheHarvester legal?

theHarvester is legal when used with authorization on domains you own or have written permission to investigate. It uses only passive techniques querying public sources. However, always obtain explicit authorization before running it against any domain. Unauthorized reconnaissance may violate computer fraud laws.

Does TheHarvester require API keys?

No, theHarvester works without API keys using search engine sources (google, bing, crtsh). However, API keys for Shodan, Hunter, and SecurityTrails significantly expand results. Configure keys in config.yaml file. Free tiers are available for all three services.

Can TheHarvester run on Windows?

Yes, theHarvester can run on Windows with Python 3 installed. Install via pip: pip3 install theHarvester. Alternatively, use WSL (Windows Subsystem for Linux) for a Linux-like environment. The tool works identically on Windows, Linux, and macOS.

Can TheHarvester run on Termux?

Yes, theHarvester can run on Termux (Android). Install Python and theHarvester: pkg install python && pip install theHarvester. Some sources may have limited functionality on mobile due to network restrictions, but core email and subdomain discovery works.

What is TheHarvester used for in cyber security?

theHarvester is used for passive OSINT reconnaissance in cyber security: email enumeration for phishing simulations, subdomain discovery for attack surface mapping, employee identification for social engineering, and domain intelligence gathering for penetration testing engagements.

What is the difference between TheHarvester and Amass?

theHarvester focuses on email discovery and basic subdomain enumeration from search engines and APIs. Amass provides deeper subdomain discovery with 40+ data sources, active DNS verification, and enterprise-level attack surface mapping. theHarvester is simpler and faster; Amass is more comprehensive but requires more configuration.

Can theHarvester find email addresses from LinkedIn?

Yes, use the -b linkedin source: theHarvester -d example.com -b linkedin. This searches Bing for LinkedIn profiles associated with the target domain, extracting employee names and email patterns. Combine with -b google for additional email discovery. LinkedIn source results depend on Bing's indexing of public LinkedIn profiles.

How do I configure API keys for theHarvester?

Edit the config.yaml file in theHarvester's installation directory (~/.theHarvester/config.yaml or /etc/theharvester/config.yaml). Add your API keys for Shodan, Hunter, SecurityTrails, and other services. Free tiers are available for Shodan (limited queries), Hunter (50 requests/month), and SecurityTrails (50 queries/month). API keys significantly expand results beyond basic search engine sources.

What is the difference between theHarvester and Recon-ng?

theHarvester focuses on email and subdomain discovery from search engines and public APIs with a simple single-command interface. Recon-ng is a full-featured reconnaissance framework with modules for multiple OSINT tasks, database storage, and reporting. theHarvester is better for quick email discovery; Recon-ng is better for structured multi-phase reconnaissance campaigns.

Can theHarvester enumerate subdomains without DNS brute-force?

Yes, use sources like crtsh (certificate transparency), dnsdumpster, and search engines (google, bing) which discover subdomains passively without DNS brute-force. The -s flag enables DNS brute-force which actively queries potential subdomain names. For passive-only discovery, omit -s and use -b crtsh,google,bing for results that do not directly interact with the target's DNS infrastructure.

How do I export theHarvester results to CSV?

Use the -f flag with an HTML output file, then convert to CSV: theHarvester -d example.com -b all -f results.html. For direct CSV, pipe results through text processing: theHarvester -d example.com -b all 2>&1 | grep -E '^[^@]*@' > emails.csv. The -f flag generates a structured HTML report with all discovered emails, subdomains, and hosts organized by category.

What API keys does theHarvester need and how do I configure them?

theHarvester requires API keys for full source functionality. Add your keys to /etc/theHarvester/api-keys.yaml: shodan: YOUR_KEY, hunterio: YOUR_KEY, securitytrails: YOUR_KEY, censys: YOUR_ID:YOUR_SECRET. Free tiers are available for Shodan (limited queries) and SecurityTrails (50 queries/month). Without API keys, only passive sources like crtsh and DNS work.

How do I use theHarvester for red team operations?

For red team operations, combine theHarvester's email discovery with password spraying using CrackMapExec. Run: theHarvester -d target.com -b all -f harvest.html to gather emails, then extract them for use in phishing campaigns or credential attacks. Use the -p flag to DNS-brute-force subdomains that may host vulnerable services, then chain with Nmap or Masscan for port scanning.

Can theHarvester discover employee names and job titles?

Yes, theHarvester can find employee names from LinkedIn, Hunter, and other professional sources using -b linkedin or -b hunter. Use the --limit flag to control the number of results. Employee names reveal organizational structure, identify high-value targets for social engineering, and help craft targeted phishing emails with realistic job titles.

How do I combine theHarvester with Subfinder for maximum coverage?

Run both tools and merge results: theHarvester -d target.com -b all -f harvest.html && subfinder -d target.com -o subfinder.txt. Extract subdomains from theHarvester's HTML output and merge with subfinder results using: sort -u merged.txt. This passive combination avoids DNS brute-force detection while maximizing subdomain coverage from both tool databases.

What is the difference between theHarvester passive and active modes?

Passive mode (-b crtsh,bing,duckduckgo) queries third-party sources without touching the target's infrastructure, generating zero network traffic to the target. Active mode adds -s for DNS brute-force, which actively queries potential subdomain names on the target's DNS servers. Use passive-only for stealthy recon and active for comprehensive discovery when detection is acceptable.

Is theHarvester legal to use?

theHarvester itself is legal software, and querying public sources like search engines and certificate transparency logs is generally lawful because the data is already public. However, using the gathered emails, names, or subdomains to attack, phish, or access systems you do not own is illegal in most jurisdictions. Only run theHarvester against domains you own or have explicit written authorization to assess, such as a signed penetration-testing scope or an in-scope bug-bounty program.

Why does theHarvester return no results or empty output?

Empty results usually mean the chosen source was rate-limited, blocked, or requires an API key you have not configured. Search engines like Google and Bing frequently throttle automated queries, so switch to -b crtsh or -b duckduckgo, add API keys for Shodan and Hunter, and confirm outbound DNS and HTTPS are not blocked by a proxy. Also verify the domain is spelled correctly and actually has public records — small or newly registered domains legitimately return little data.

How is theHarvester different from Subfinder and Amass?

theHarvester is a broad OSINT collector that gathers emails, employee names, subdomains, ports, and banners, making it ideal for the very first reconnaissance pass. Subfinder and Amass are specialized subdomain-discovery tools that pull from far more sources and scale to enterprise attack-surface mapping. In practice you run theHarvester first for people-and-email intelligence, then use Subfinder or Amass to exhaustively enumerate subdomains, and merge the results for maximum coverage.

Does theHarvester work on Windows and macOS?

Yes. theHarvester is a Python 3 application, so it runs anywhere Python 3.9+ is available. On macOS use Homebrew (brew install theharvester) or pipx; on Windows use pip inside a virtual environment or run it under WSL for the closest Linux-like experience. On Kali and most Debian-based Linux it is available directly via apt. Docker is the most portable option because it bundles every dependency.

How do I save and share theHarvester results?

Use the -f flag to write output to a file, e.g. theHarvester -d example.com -b all -f report. Modern versions produce an HTML report plus a JSON file you can feed into other tools, while older versions accept -f report.xml. Store one report per engagement with a dated filename, and sanitize it before sharing because it can contain internal hostnames and staff email addresses.

Which theHarvester sources need API keys and which are free?

Free sources that need no key include crtsh (certificate transparency), duckduckgo, bing, otx, rapiddns, and threatminer. Sources that require an API key include shodan, hunter, securitytrails, censys, and github. Add keys to the api-keys.yaml file; most providers offer a limited free tier, so you can start without paying and upgrade only if you need higher query volumes.

Is theHarvester still maintained in 2027?

Yes. theHarvester is actively maintained by Christian Martorella (laramies) and contributors on GitHub, with regular releases that add new data sources and fix broken scrapers as third-party sites change. Because sources break often, keeping theHarvester updated (apt upgrade, pipx upgrade, or pulling the latest Docker image) is important for reliable results.

Tags

#reconnaissance#osint#email-harvester#subdomain-discovery#passive-recon#domain-intelligence#cyber-security#kali-linux

Output Explanation

theHarvester output is organized into structured blocks: Emails (discovered email addresses with source attribution), Subdomains (DNS-resolved subdomains with IP addresses), Hosts (resolved IP addresses and open ports), Virtual Hosts (web servers hosting the domain), Banners (service banners from Shodan), and Employee Names (LinkedIn and social media profiles). A first scan such as `theHarvester -d example.com -b crtsh,certspotter -l 500 -f first-scan` prints lines like `[crtsh] api.example.com` and `[crtsh] mail.example.com` under Subdomains/Hosts — each line is a certificate-derived candidate hostname, not proof the host is live, so verify it with `-v` or `-n` before passing it on. An Emails line such as `[bing] admin@example.com` means Bing returned that address from indexed data, not that the mailbox is valid. Focus on email addresses for phishing-campaign planning, subdomains for attack surface mapping, and open ports for service enumeration, and open the saved `first-scan.html` report to review everything in one place.

Ethical Usage Notice

This tool is designed for authorized security testing, educational purposes, and legitimate network administration only. Unauthorized access to computer systems is illegal.