Different Letters

Add prefix and suffix to lines

Add the same text at the beginning or end of each line, with optional numbering and blank-line handling.

0 / 20,000

Each line keeps its line break. Numbering comes before the prefix.

Result

Your result will appear here.

Format each line without rewriting its contents

A prefix is text placed before a line, and a suffix is text placed after it. Paste your list into Text, enter either or both additions, and select Apply. The tool keeps the existing line contents and surrounds each processed line with the same additions. You can use it to add labels, brackets, short path fragments or other repeated text without editing each item separately.

Put one item on each actual line before starting. The tool does not split entries at commas, semicolons or spaces. A paragraph containing several names on one line remains one item and receives one prefix and one suffix. A long entry that wraps onto several display rows is still one line unless the input contains a real line break at that point.

You can leave either addition empty. A prefix on its own adds text only at the beginning; a suffix on its own adds text only at the end. Leaving both empty can still be useful when Number lines is enabled. With both additions empty and numbering off, the operation has nothing to add and returns the supplied text without changing the item contents.

The output is separate from the input. Applying the same settings again does not automatically add another layer to the previous result because the operation still reads the original input field. To intentionally add another layer, copy the output back into the input first. Keep an undecorated copy of the list until you have checked the result, especially if you plan to run several formatting steps.

Include spaces and punctuation exactly where you need them

The tool does not insert an automatic space between your prefix and the line. If you want a label followed by a space, type that space as part of the prefix. Likewise, a suffix that should be separated from the original text must include its own leading space. This lets you choose tight wrapping such as brackets or spaced formatting such as a label followed by a description.

For a simple example, put β€œalpha” and β€œbeta” on separate lines. Set the prefix to β€œ[” and the suffix to β€œ]”. With numbering off, the two result lines are β€œ[alpha]” and β€œ[beta]”. No spaces are inserted inside the brackets. If the input already has a space before alpha, that space stays inside the new brackets rather than being removed or moved outside them.

The original text is not trimmed. Leading indentation, trailing spaces, punctuation and repeated entries remain in their original positions within each line. A suffix follows the whole line, including any trailing spaces. If a bracket appears farther from the last visible letter than expected, inspect those spaces in the source. The tool adds surrounding content; it is not a whitespace-cleaning operation.

All additions are literal. A dollar sign, asterisk or pair of braces is inserted as typed rather than expanded into a variable or a matching expression. Writing a placeholder such as {name} does not substitute each line into that placeholder. The line itself simply appears between the prefix and suffix. The controls are single-line fields, not a template language for building different content for each item.

Preserve blank separators or decorate them deliberately

Keep separators between groups

Skip blank lines is selected initially. With that option on, an empty line remains in the output but receives no prefix, suffix or number. A line containing only whitespace is also skipped and preserved. This is useful when blank lines separate groups that you want to keep visually distinct. β€œSkip” means leave those lines alone, not delete them from the list.

For example, enter alpha, then a blank line, then beta. With β€œ[” as the prefix, β€œ]” as the suffix and Skip blank lines on, the output contains β€œ[alpha]”, the same blank separator and β€œ[beta]”. Turn the option off and the blank line becomes β€œ[]”. The two populated lines stay wrapped in the same way. Choose according to whether an empty row is a separator or an item that needs decoration.

Check whitespace and the final line break

A whitespace-only line behaves similarly, but its existing spaces remain. With skipping off, the additions surround those spaces rather than replacing them with a truly empty string. If numbering is enabled, that line also consumes a number. If skipping is on, it receives no number and does not advance the sequence. This distinction matters when blank rows come from a copied spreadsheet or grouped note.

A final line break ends the last line; it does not create an additional empty item after it. A list ending with alpha and a final line break therefore gets one decorated item, not an extra pair of brackets on a new final row. Internal blank lines are still real lines. Distinguishing an internal separator from the end of the last line prevents an unwanted extra item at the bottom.

Number processed lines from a chosen starting point

Number lines is optional and begins switched off. Turn it on to add a decimal number, a period and a space before each processed line. The starting value is initially 1. You can choose a whole number from 0 to 1,000,000; negative values, fractions and an empty starting value are not accepted when numbering is enabled. Choose the start before applying the transformation.

The order is always number, prefix, original line, then suffix. For example, use alpha, a blank line and beta as the input, set the prefix to β€œ[”, the suffix to β€œ]”, keep Skip blank lines on and start at 8. The first item becomes β€œ8. [alpha]”, the blank separator stays blank, and the next item becomes β€œ9. [beta]”. The prefix does not appear before the number.

Skipped blank lines do not consume sequence values. If you turn skipping off, they are processed and do consume a number, just like populated lines. Numbering follows the current line order; it does not sort or rank the entries. Repeated items receive their own numbers because the tool does not remove duplicates or decide that two lines refer to the same thing.

The numbering format is fixed. It does not offer zero padding, letters, Roman numerals or a custom separator after the number. Putting zeros in the starting-number field does not create an output format such as 001. If you need a literal label like β€œItem: ” as well, enter it as the prefix and remember that the generated number will still come first. Check that order against your destination's requirements.

Build useful wrappers without assuming a file format

One practical use is adding a shared path around short identifiers. With home and contact on separate lines, prefix β€œhttps://example.com/” and suffix β€œ/”, the output lines become β€œhttps://example.com/home/” and β€œhttps://example.com/contact/”. This only assembles text. It does not visit the addresses, confirm that pages exist or determine whether the paths are appropriate for a particular website.

Check the source before adding a path prefix. If the input already contains a leading slash, an existing domain or a full address, the result may repeat that part. The tool does not recognize URLs and remove duplicate separators automatically. Likewise, a suffix such as a file extension is added even when the line already ends with that extension. Start with identifiers in the form your chosen wrapper expects.

You can also place quotation marks around each item or append commas. That does not automatically produce a valid CSV, JSON array or programming-language list. Existing quotes may need escaping, embedded commas may need special treatment, and a final comma may be disallowed in the target format. This tool does not inspect those rules. Use a format-aware exporter when correctness depends on structured syntax.

For a plain checklist or review note, literal wrappers are often sufficient. Decide whether the result should be human-readable text or machine-readable data before building it. If it is intended for a command, query or script, review and validate it in the appropriate environment rather than executing it merely because each line looks well formed. Adding punctuation is not the same as validating the content inside it.

Keep the order of list operations intentional

Apply changes to the list in an order that matches the final purpose. If you want alphabetical numbering, sort the original entries first and add numbers afterward. Otherwise a later sort can place lines according to their numeric prefix instead of their item names. Use Alphabetical order for the sorting step, then return here with the ordered list to add its labels and numbers.

If repeated items should appear only once, use Remove duplicate lines before numbering. Two equal entries become different strings when they receive different numbers, which can make a later duplicate-removal pass less useful. On the other hand, keep duplicates when they represent separate records. This formatter preserves them because repetition may be intentional rather than an error to fix.

The tool cannot remove an existing prefix or suffix by choosing a negative length or leaving an addition empty. It only adds content. If you need to replace a known marker already present in the lines, Find and replace text is the separate literal-editing tool. Review that replacement carefully because matching content might also occur inside a line, not just at its boundaries.

For multiple formatting passes, copy only a result you have reviewed into the next input. Keep track of whether numbering has already been applied so that it is not added twice. A short sample containing a normal item, an indented item and a blank separator makes a useful check before processing the whole list. The sample should reflect the irregularities of your actual source, not just its cleanest lines.

Review the result and respect the size limits

The input text has a 20,000-unit limit according to the field counter. Prefix and suffix values are also checked against a 20,000-unit limit each. The result has a 200,000-unit guard. A modest input with many short lines can produce a large output because the additions are repeated for every processed line. Shorten the additions or process fewer lines if the result would be too large.

The counter uses the string length handled by the browser, not necessarily the number of symbols visible to a reader. Some emoji and combined characters use more than one unit. An error is not a complete formatted list: adjust the settings and apply again. Editing the input or an option clears the earlier output so you can distinguish the current result from an obsolete one.

Before copying, inspect the first item, an item near a blank line and the final item. Confirm spaces, numbering and the position of the suffix. After using Copy result, inspect the pasted version in the destination too. The operation preserves the line separators it receives, but a browser text field or another application can normalize line endings. This is not a byte-for-byte file conversion service.

Back to the tool