Updated Jul 15, 2026

Utilities

Turn bare hosts into URLs with a line prefix

Prepend one string to each line in a file or folder.

Agent

overview

What prefix-file-lines does

Sit prefix-file-lines between recon output and any stage that expects scheme-qualified URLs or rooted paths.

Operators reach for it when a host list, wordlist, or merge sink needs the same prefix on every line without writing a script.

Inputs are file or folder plus prefix-string. For end-of-line stamps use suffix-file-lines; for structured URL rewrite use unfurl or qsreplace.

use cases

Where prefix-file-lines fits

Turn bare hosts into URLs

Prefix a list of hostnames with https:// so a crawler or HTTP prober downstream receives well-formed URLs instead of bare names.

Adapt one tool's output to the next tool's input

Add the scheme, parameter, or label a downstream node expects so two stages connect without a custom script in between.

Tag results before a merge

Prefix each line with a source marker so that when several files merge into one sink, you can still tell where each entry came from.

reference

prefix-file-lines inputs and flags

3 inputs
NameTypeFlagDescription
fileFILE·Folder with files that need a prefix for each line
folderFOLDER·Folder with files that need a prefix for each line
prefix-stringSTRING·String that will be appended to each line.

Showing key inputs. prefix-file-lines exposes 3 inputs in total.

example

Run prefix-file-lines

prefix-file-lines · command
# prefix-file-lines: turn hosts into https URLsprefix-file-lines --prefix 'https://' hosts.txt
sample output
https://www.example.comhttps://api.example.comhttps://dev.example.comhttps://staging.example.comhttps://mail.example.com

guidance

Choosing prefix-file-lines

Use when the next stage needs a fixed prefix on every line, such as https:// on bare hosts. Prefer suffix-file-lines to append. Prefer unfurl or qsreplace for component-level URL edits.

suffix-file-lines

Mirror tool that appends a string to the end of each line instead of the start.

unfurl

Parses and reformats URL components. Use when you need structured rewrite, not a flat prefix.

anew

Appends only new unique lines to a file. Pair with a prefix step when deduping a growing list.

faq

prefix-file-lines questions

Yes. Pass folder and it prefixes every line in every file inside, not only a single file input.

Run prefix-file-lines yourself

A host list feeds prefix-file-lines, which prepends https:// to each line and hands the URLs to httpx for probing before they land as output.

Facts on this page come from the live Trickest tool library.