Text to HTML Converter
WM-70Paste plain text and get HTML with paragraphs, line breaks and links. Special characters are escaped, so the text shows exactly as typed.
Runs in your browser. Nothing is uploaded.
Plain text
HTML
How to use it
- Paste your text into the input box, or open a .txt file and drop it on the box.
- Choose what a single line break becomes: br, a newline, or a new paragraph.
- Leave Link web addresses on to make http and https addresses clickable.
- Copy the HTML, or switch to Preformatted to keep every space and line.
Paragraphs and line breaks
A blank line starts a new paragraph, and each paragraph is wrapped in p tags. A single line break inside a paragraph becomes a br tag by default, which keeps addresses and poems readable. You can instead leave it as a newline in the source, which browsers show as a space, or turn every non-empty line into its own paragraph. Leading and trailing blank lines are removed.
Escaping and links
The characters & < and > are escaped, so angle brackets in your text show as typed and cannot become tags. With Link web addresses on, text that starts with http:// or https:// becomes a link, and a trailing . , ; : ! ? ) or ] stays outside the link. Email addresses and addresses that start with www. are not linked. There is no Markdown or other formatting in the conversion.
Preformatted and full page
Preformatted wraps the whole text in a pre element, which keeps every space, tab and line break, and is the right choice for code, tables made of spaces or logs. The page option wraps the paragraphs in a minimal HTML document with the title Document, which you should change. Leading spaces are kept in the output, but browsers collapse them outside pre.
Error messages and what to do
| Message | What it means | Fix |
|---|---|---|
Type or paste some text to convert. | The input is empty or only whitespace. | Paste the text you want to convert. |
Questions people ask
How do I convert plain text to HTML?
Paste your text and choose Paragraphs. Blank lines become paragraph breaks and single line breaks become br tags. Copy the HTML or download it as a .html file.
Does it escape special characters?
Yes. Ampersands and angle brackets are escaped, so a line like Tom & Jerry <3 shows exactly like that on a page. Everything runs in the page, so you can test with real data.
Will it make links clickable?
Yes, for addresses that start with http:// or https://. Punctuation at the end of a sentence stays outside the link. Turn the option off if you do not want links.
How do I keep my spacing and indentation?
Use Preformatted. It wraps the text in a pre element, and browsers display every space and line break as written. If the output is not what you expect, check the input first.
Can I get a full HTML page?
Turn on Wrap in a full HTML page. It adds a doctype, html, head and body around your paragraphs. Change the generic title before you publish it.
About this tool
Paragraphs splits your text at blank lines and wraps each block in <p>. A single line break inside a block becomes <br> by default; you can keep it as a newline in the source, or make every non-empty line its own paragraph. Text is HTML-escaped (& < >), so angle brackets show as typed. With Link web addresses on, anything that starts with http:// or https:// becomes a link, and trailing punctuation such as . , ; : ! ? ) or ] stays outside the link; email addresses and www. addresses are not linked. Preformatted wraps the whole text in <pre> and keeps every space and line break; the link option is off there unless you turn it on. There is no Markdown or other formatting. The page option adds a minimal HTML skeleton with the title Document, which you should change. Leading spaces are kept in the source, but browsers collapse them outside <pre>.