Add Prefix and Suffix to Lines
Add text before and after every line or word: prefixes, suffixes, quotes, brackets or HTML tags like <li>, with {n} numbering. Remove mode strips them again.
Adding the same text to the start or end of many lines is tedious by hand: bullets for a list, quotes and commas for code, <li> tags for a web page, file paths, hashtags or SQL values. Paste your lines, type a prefix and a suffix, or choose a wrapping such as quotes, brackets or an HTML tag, and every line (or every word) gets it at once. Use {n} for running numbers, and switch to Remove to strip prefixes, suffixes and wrappers again.
How to use this tool
- Paste your lines.
- Type the prefix and suffix, using {n} where you want a running number.
- Optionally wrap each item in quotes, brackets or an HTML tag, and choose lines or words.
- Copy the result, or choose Remove to take the same prefix, suffix or wrapping off again.
Formula
New line = prefix + opening wrapper + line + closing wrapper + suffix, with {n} = start, start + 1, …
Empty lines are skipped by default and do not use up a number. Inside HTML tags, the characters &, < and > in your text are escaped so the result is valid HTML; turn that off if your lines already contain HTML. In Remove mode the prefix must match the start of the line exactly and the suffix the end (case-sensitive), {n} matches any number, and a wrapper is removed only when it appears at both ends.
Example
The lines red, green and blue with the prefix {n}) become 1) red, 2) green and 3) blue. With a single quote as the prefix and a quote plus comma as the suffix you get 'red', 'green', 'blue', ready for a SQL list, and wrapping in <li> gives three list items for a web page.
Frequently asked questions
How do I add a comma to the end of every line?
Leave the prefix empty and type a comma as the suffix. To quote each item as well, choose a quote wrapping; the comma is added after the closing quote.
Can I add a number to each line?
Yes. Put {n} in the prefix or suffix, for example “{n}. ”, and set where numbering starts. For more numbering styles, such as Roman numerals or letters, use the line numbering tool.
How do I remove quotes from every line?
Choose Remove, clear the prefix and suffix, and choose the matching wrapping (double or single quotes). Only quotes at both ends of a line are removed.
Last updated:
Page address with these inputs: https://kakao.mobile/tools/line-prefix-adder/
Cite or embed this tool
kakaoCalc. (2026, November 8). Add Prefix and Suffix to Lines. https://kakao.mobile/tools/line-prefix-adder/
“Add Prefix and Suffix to Lines.” kakaoCalc, 8 Nov. 2026, kakao.mobile/tools/line-prefix-adder/.
Paste this code into your page. The widget runs in your visitors' browsers, shows no ads and keeps a link back to this page. Embedding terms