Skip to content
TextArray
100% local

Lines to HTML list

Convert line-separated text into properly formatted HTML list markup.

Input

Lines to HTML list

Paste a list of items, one per line, and this tool wraps them in standard HTML list markup. Each line becomes a li element inside either a ul (unordered) or ol (ordered) container. The output is valid, escaped HTML ready to paste into a page or CMS.

Blank lines are automatically skipped, so gaps in your input won't create empty list items. Special HTML characters like &, <, > and " are properly escaped in each item, preventing injection errors and ensuring the text renders as intended even if it contains code-like content.

Use the list type option to choose between unordered (bullet points) and ordered (numbered) lists. The indent option controls whether each item gets two spaces of indentation for readability — helpful when you're building HTML by hand and want clean formatting, or omit it for compact output.

This is handy for developers working with static HTML, CMSs, or static site generators where you need to convert a simple checklist or outline into markup. The tool runs entirely in your browser, so your list never leaves your device. Copy the output directly or download it as an HTML file.

FAQ

Do blank lines become empty list items?
No. Blank lines are skipped entirely, so only non-empty lines generate li elements. This makes it safe to have gaps in your source list without cluttering the output.
How are special characters handled?
The &, <, > and " characters are HTML-escaped to their entity forms (ampersand, lt, gt, quot) so they render correctly and don't break the markup. Your content is always safe.
What if I need a different format like Markdown or XML?
TextArray has separate tools for Markdown lists, CSV export, and other formats. Choose the one that matches your target output, or use this tool as a starting point and convert further in your editor.
Is my text uploaded anywhere?
No. The tool runs entirely in your browser and your text never leaves your device.
Can I change the indentation?
Yes. Toggle the indent option on or off. When it is on, each item gets two spaces; when off, the output is more compact.