Code → 2l.nz

Code to link

Pasting forty lines into a chat window helps nobody. A 2L link gives them the same code with highlighting, line numbers and a line you can point at.

Drop anything. Get a link.

Drag it here, paste it, or press to choose a file. 2L works out what it is and shows it properly.

25 MB per file 10 files per link kept 7 days no account needed — what an account adds

What you get

Not just somewhere to put it.

The link is the easy part. What matters is the page on the other end of it.

The language is worked out for you

From the file extension when there is one, and from the syntax when there is not — so a snippet pasted straight out of an editor still arrives highlighted.

Line numbers you can link to

Click a line number and the URL points at that line. Send someone “line 42” without saying “line 42”.

Raw is one click away

A raw view serves the exact text, so it can be piped into curl or fed to a tool without anything in between.

Questions

About code to link

Which languages are highlighted?
Around sixty, covering the common ones: JavaScript and TypeScript, Python, Go, Rust, Java, C and C++, C#, Ruby, PHP, Swift, Kotlin, SQL, shell, YAML, TOML, HCL and the rest. Anything unrecognised is shown as clean plain text rather than mis-highlighted.
Can I share several files at once?
Yes. Drop a set of files and the link holds all of them, each with its own highlighting.
Does it run the code?
No, never. Code is shown as text. The one thing that is ever executed is an HTML drop, and that runs inside a sandbox with no access to 2L or to your session.
Is there an API?
Yes, on Pro. One POST returns a link, which is enough to wire it into a CI job or an editor plugin.
Everything else

The same box takes all of it.

There is no format menu anywhere in this product. These pages exist because people search for them, not because 2L works differently for each one.