One insertion, at character zero
Prepend is inserted verbatim at the start of the input. There is no scope, no per-line behaviour, no skip-empty switch. The implementation is a one-liner: (prepend || '') + s. If Prepend is empty the input passes through unchanged.
The string can contain newline characters by typing them into the field (where the browser allows it) or by pasting a multi-line value. The whole content sits before the first character of your existing text. So Prepend = HEADER\n\n produces a header line and a blank line, then your original text.
For a header that repeats on every line, use add prefix to each line with Scope = Whole Text. For appending to the bottom instead, use add text to bottom.
How to use add text to the top
- 1Paste your text into the input panel on the left.
- 2Type the string you want to insert at the top into the Prepend field.
- 3If you want a blank line between the prepended string and your text, include a trailing newline in Prepend.
- 4Read the result on the right; the prepended string is at the very start.
- 5Click Copy or Download in the output header.
Keyboard shortcuts
Drive TextResult without touching the mouse.
| Shortcut | Action |
|---|---|
| Ctrl F | Open the find & replace panel inside the input Plus |
| Ctrl Z | Undo the last input change |
| Ctrl Shift Z | Redo |
| Ctrl Shift Enter | Toggle fullscreen focus on the editor Plus |
| Esc | Close find & replace, or exit fullscreen |
| Ctrl K | Open the command palette to jump to any tool Plus |
| Ctrl S | Save current workflow draft Plus |
| Ctrl P | Run a saved workflow Plus |
What this tool actually does
Single insertion at position zero
The transform is prepend + input. There is exactly one insertion, at the very start of the text. No splitting, no per-line work.
Prepend is verbatim
The string you type lands in the output unchanged, including any whitespace, line breaks, or special characters. No escaping, no trimming.
Empty Prepend is a no-op
If you leave the field empty the input is returned unchanged. There is no implicit header.
Multi-line prepends are supported
Paste a multi-line value into Prepend to insert a multi-line header. The line breaks in the prepend are preserved exactly.
Pair with append for top-and-tail wrapping
Combine with add text to bottom to wrap the whole block top and tail. Useful for adding <pre> ... </pre>, [ ... ], or BEGIN / END markers.
Worked example
Prepend // auto-generated, do not edit\n. The header line lands at the top, then the original code follows verbatim.
function greet(name) {
return 'hi, ' + name;
}
// auto-generated, do not edit
function greet(name) {
return 'hi, ' + name;
}
Settings reference
| Behaviour | Effect on output |
|---|---|
| Prepend populated | Inserted verbatim at the very start of the input. |
| Prepend empty | Input passes through unchanged. |
| Prepend with line breaks | Multi-line headers are supported. Newlines are inserted as typed. |
| Existing input | Untouched. Only the very start gets the new string. |
| Line endings | Original input bytes are preserved verbatim. |
FAQ
How do I add a blank line between the header and the rest of the text?
Can I prepend a multi-line block?
What if I want a header on every line?
Per Line.