# Holehe CLI Options: Complete Command-Line Reference

> Discover Holehe CLI options for email checking. Explore arguments, output filters like --only-used, CSV export, and network settings. Get the complete command-line reference.

- Repository: [Palenath/holehe](https://github.com/megadose/holehe)
- Tags: api-reference
- Published: 2026-08-17

---

**Holehe provides seven command-line options—including a required email argument, output filters like `--only-used`, export controls such as `--csv`, and network settings including `--timeout`—all implemented in [`holehe/core.py`](https://github.com/megadose/holehe/blob/main/holehe/core.py) using Python's `argparse` module.**

The open-source OSINT tool Holehe allows security researchers to check if an email address is registered on various websites via its command-line interface. Understanding the full range of Holehe CLI options enables efficient automation, filtering of results, and integration into external workflows. This guide examines the argument parser implementation in the megadose/holehe repository and explains how each flag modifies the tool's behavior.

## Core CLI Implementation in holehe/core.py

Holehe's command-line interface is constructed using Python's standard `argparse` module. In [`holehe/core.py`](https://github.com/megadose/holehe/blob/main/holehe/core.py), line 180 instantiates the `ArgumentParser` class, followed by sequential calls to `parser.add_argument` that define the available options.

The parser configuration establishes one required positional argument and several optional flags that control output formatting, password-recovery behavior, CSV export capabilities, and network timeouts.

## Available Holehe CLI Options

The following options are parsed at program start and stored in the `args` namespace for access throughout the execution flow.

### Target Email (Required Positional Argument)

The only required input is the email address to investigate:

```bash
holehe user@example.com

```

According to the source code at line 183, this positional argument is defined without a flag and represents the target account to test across supported services.

### Output Filtering Flags

**`--only-used`**  
Shows only the sites where the email address is actually registered, filtering out services that return "not found" status. In the execution flow, the tool checks `args.onlyused` to determine whether to suppress negative results (source: line 185).

**`--no-color`**  
Disables colored terminal output. This is useful when redirecting output to files or running in CI/CD pipelines. The flag sets `args.nocolor`, which the `print_result` function and [`holehe/instruments.py`](https://github.com/megadose/holehe/blob/main/holehe/instruments.py) utilities respect to toggle ANSI color codes (source: line 187).

**`--no-clear`**  
Prevents the terminal screen from being cleared before displaying results. This preserves previous terminal history when piping output to other tools or logging systems (source: line 189).

### Password Recovery Control

**`-NP` / `--no-password-recovery`**  
Skips password-recovery attempts on tested services, reducing noise and execution time. When this flag is present, Holehe omits modules that attempt to trigger password reset flows (source: line 191).

### Data Export Options

**`-C` / `--csv`**  
Generates a CSV file containing the full result set. The `export_csv` function in [`holehe/core.py`](https://github.com/megadose/holehe/blob/main/holehe/core.py) handles file generation when this flag is detected in the `args` namespace (source: line 193).

### Network Configuration

**`-T` / `--timeout`**  
Sets the maximum request timeout in seconds. The default value is **10 seconds**, configurable via this flag. This controls how long Holehe waits for HTTP responses from individual services before marking them as timeouts (source: line 195).

## Practical Usage Examples

Basic reconnaissance of a single target:

```bash
holehe alice@example.com

```

Display only confirmed registrations without colored output, exporting to CSV:

```bash
holehe alice@example.com --only-used --no-color --csv

```

Skip password recovery checks with increased timeout for slow networks:

```bash
holehe alice@example.com --no-password-recovery --timeout 30

```

Preserve terminal history while running in automation scripts:

```bash
holehe alice@example.com --no-clear --csv > results.csv

```

## How Arguments Drive Execution

Once parsed, the `args` namespace object propagates through the application logic. For example:

- `args.onlyused` determines filtering logic in the result display phase
- `args.nocolor` disables ANSI sequences in [`holehe/instruments.py`](https://github.com/megadose/holehe/blob/main/holehe/instruments.py) rendering functions
- `args.csv` triggers the `export_csv` function call before program termination

The package version displayed in the help header originates from [`holehe/__init__.py`](https://github.com/megadose/holehe/blob/main/holehe/__init__.py), ensuring consistency between the CLI interface and the installed package metadata.

## Summary

- Holehe defines seven CLI options in [`holehe/core.py`](https://github.com/megadose/holehe/blob/main/holehe/core.py) using Python's `argparse` module at line 180
- The only required argument is the target `email` address; all other flags are optional
- Output control (`--only-used`, `--no-color`, `--no-clear`) allows integration with logging systems and CI pipelines
- The `--csv` flag invokes the `export_csv` function to generate machine-readable output files
- Network behavior is adjustable via `--timeout` with a default of 10 seconds
- Password-recovery modules can be bypassed using `-NP` to improve execution speed

## Frequently Asked Questions

### How do I export Holehe results to a CSV file?

Use the `-C` or `--csv` flag when invoking the tool. This triggers the `export_csv` function in [`holehe/core.py`](https://github.com/megadose/holehe/blob/main/holehe/core.py) to write the complete result set to a CSV file in the working directory. You can combine this with `--only-used` to export only confirmed registrations.

### Can I disable colored output when running Holehe in scripts?

Yes. Append the `--no-color` flag to disable ANSI color codes. This sets `args.nocolor` in the parser namespace, which the rendering utilities in [`holehe/instruments.py`](https://github.com/megadose/holehe/blob/main/holehe/instruments.py) check before applying terminal formatting. This option is essential when piping output to files or running in non-interactive environments.

### What is the default timeout for network requests in Holehe?

The default request timeout is **10 seconds**. You can modify this threshold using the `-T` or `--timeout` flag followed by the desired number of seconds. This value is defined at line 195 in [`holehe/core.py`](https://github.com/megadose/holehe/blob/main/holehe/core.py) and controls how long the tool waits for HTTP responses from each service before marking the check as timed out.

### Does Holehe require any arguments besides the email address?

No. The email address is the only required positional argument, defined at line 183 in [`holehe/core.py`](https://github.com/megadose/holehe/blob/main/holehe/core.py). All other options—including `--only-used`, `--csv`, and `--timeout`—are optional flags that modify default behavior but are not necessary for basic operation.