View code with syntax highlighting, copy and download.
The Source Code Viewer shows pasted or opened code with syntax highlighting in an editor-style panel. You can pick a language or let it auto-detect, then copy the code or download it as a file with a matching extension. It suits developers who want to read, share or save a snippet without opening an IDE.
Syntax highlighting colours the parts of source code, such as keywords, strings, numbers and comments, so its structure is easy to scan. A highlighter works by tokenising the text according to the grammar of a language and assigning a style to each token type. It does not run or validate the code, so it will colour broken code just as happily as working code. Highlighters often guess the language from characteristic keywords, which is reliable for distinct languages but can misjudge short or ambiguous snippets. Choosing the language explicitly always gives the most predictable colouring.
No. It only tokenises and colours the text. Nothing is run, compiled or validated.
No. The tool states that it never fetches code from URLs. Paste the text or open a local file instead.
Auto-detect plus JavaScript, TypeScript, JSON, HTML, XML, CSS, SQL, Python, Java, C#, C++, Go, Rust, PHP, Ruby, Bash, YAML, Lua and Markdown.
If you opened a file, its original name is used. Otherwise the name is code followed by an extension based on the active language, falling back to .txt for anything unmapped.
The panel is an editable text area with highlighting, so you can change the text, then copy or download your edited version.