Configuration¶
rewget can be configured through command-line flags and environment variables.
Environment Variables¶
| Variable | Description | Default |
|---|---|---|
RWGET_ENGINE | Default wget engine (wget or wget2) | wget |
Command-Line Flags¶
All rewget-specific flags use the --rewget-* prefix to avoid conflicts with wget flags.
Core Options¶
--rewget-no-fallback¶
Disable fallback completely. rewget behaves exactly like wget.
--rewget-engine=ENGINE¶
Select the wget engine to use.
| Value | Description |
|---|---|
wget | GNU Wget (default) |
wget2 | GNU Wget2 |
--rewget-quiet¶
Suppress rewget status messages. wget's output is unchanged.
--rewget-debug¶
Enable verbose debug output for troubleshooting.
Fallback Control¶
--rewget-fallback-codes=CODES¶
Comma-separated HTTP status codes that trigger fallback.
Default: 403,429,503,520,521,522,523,524,525,526,527,528,529
--rewget-fallback-stage=N¶
Start at a specific stage instead of Stage 1.
| Value | Stage |
|---|---|
1 | Plain wget (default) |
2 | TLS impersonation |
3 | JavaScript preflight |
--rewget-no-body-detection¶
Disable HTML body pattern detection for bot protection signatures.
Browser Profile Options¶
--rewget-profile=NAME¶
Use a specific browser profile for impersonation.
Available profiles:
| Profile | Browser |
|---|---|
chrome_131 | Chrome 131 on Windows |
chrome_130 | Chrome 130 on Windows |
firefox_136 | Firefox 136 on Windows |
firefox_133 | Firefox 133 on Windows |
safari_18 | Safari 18 on macOS |
edge_131 | Edge 131 on Windows |
--rewget-list-profiles¶
List all available browser profiles.
--rewget-update-profiles¶
Update browser profiles from the remote server.
--rewget-profile-url=URL¶
Custom URL for profile updates.
--rewget-no-verify¶
Skip Ed25519 signature verification when updating profiles.
Warning
Only use this for testing or with trusted profile sources.
--rewget-verify-profile=NAME¶
Display detailed fingerprint information for a profile.
JavaScript Preflight Options¶
--rewget-js¶
Force JavaScript preflight (Stage 3) from the start.
--rewget-js-wait=CONDITION¶
Wait condition for JavaScript preflight.
| Condition | Description |
|---|---|
networkidle | Wait for network to be idle |
selector:CSS | Wait for CSS selector to match |
delay:MS | Wait fixed milliseconds |
rewget --rewget-js --rewget-js-wait=networkidle https://example.com/
rewget --rewget-js --rewget-js-wait=selector:#main-content https://example.com/
rewget --rewget-js --rewget-js-wait=delay:5000 https://example.com/
--rewget-download-chromium¶
Pre-download Chromium for JavaScript preflight.
--rewget-chromium-path¶
Print the Chromium installation path.
Timeout Options¶
--rewget-timeout-stage1=MS¶
Stage 1 timeout in milliseconds. Uses wget's timeout settings by default.
--rewget-timeout-stage2=MS¶
Stage 2 timeout in milliseconds.
Default: 15000 (15 seconds)
--rewget-timeout-stage3=MS¶
Stage 3 timeout in milliseconds.
Default: 30000 (30 seconds)
Cache Options¶
--rewget-no-cache¶
Disable domain stage caching. Always start at Stage 1.
--rewget-clear-cache¶
Clear the domain stage cache and exit.
Daemon Options¶
--rewget-daemon=MODE¶
Control daemon behavior.
| Mode | Description |
|---|---|
auto | Start daemon when needed (default) |
on | Always use daemon |
off | Never use daemon (Stage 1 only) |
Information Options¶
--rewget-version¶
Print rewget version and exit.
--rewget-help¶
Print help message and exit.
--rewget-completions=SHELL¶
Generate shell completions.
| Shell | Value |
|---|---|
| Bash | bash |
| Zsh | zsh |
| Fish | fish |
| PowerShell | powershell |
File Locations¶
| File | Location | Description |
|---|---|---|
| Stage cache | ~/.cache/rewget/stage-cache.json | Domain → stage mapping |
| Profiles | ~/.local/share/rewget/profiles/ | Browser profile definitions |
| Chromium | ~/.local/share/rewget/chromium/ | Chrome for Testing installation |
Configuration Precedence¶
- Command-line flags (highest priority)
- Environment variables
- Default values (lowest priority)