Hacker News

Top stories

Live mirror
30 storiesupdated just nowView source snapshot
  1. Self-parking car using genetic algorithm (2021) (trekhleb.dev)
    4comments
  2. Ember-1 (fireworks.ai)
    185comments
  3. When did Google get so weird? (sancho.bearblog.dev)
    452comments
  4. Research finds 485 chemicals in US pesticide products linked to breast cancer (theguardian.com)
    6comments
  5. Alan Kay's answer to “Did the ENIAC have a BIOS”? (quora.com)
    30comments
  6. There is more to code review than (automatable) detection (adaptivecapacitylabs.com)
    36comments
  7. The state of SIMD in Rust in 2026 (shnatsel.github.io)
    21comments
  8. Guitar amp and effects pedal built on the Waveshare ESP32-S3-Touch-AMOLED-2.06 (github.com/dashersw)
    4comments
  9. Show HN: Lofi Cities – Pixel-art city nights with browser-generated lofi (loficities.com)
    82comments
  10. Lunar Terminator Paradox (secretsauce.net)
    32comments
  11. Malleable software: Restoring user agency in a world of locked-down apps (2025) (inkandswitch.com)
    1comments
  12. Self-Hosting on the Dark Web (alvarezrosa.com)
    24comments
  13. Don't couple your Go code to GitHub (iain.rocks)
    79comments
  14. Imp is a full port of DSPy to the BEAM (github.com/deepfates)
    5comments
  15. What I did at Recurse Center (thill.me)
    18comments
  16. Show HN: Panda, the world's first personal AI computer (pandax1.com)
    19comments
  17. As A.I. Makes Law Firms More Efficient, Clients Ask: 'Where's My Discount?' (nytimes.com)
    4comments
  18. Oral history of John Chowning, inventor of FM synthesis [video] (youtube.com)
    10comments
  19. In an $80 motel room, a discovery to shed light on the origins of life (nytimes.com)
    82comments
  20. Replacing the old battery on rechargeable bike lights (jvns.ca)
    76comments
  21. Previously unheard recordings of John Coltrane, captured by Frank Tiberi (jazzwise.com)
    21comments
  22. Writing Efficient C++ Code (2013) (asawicki.info)
    84comments
  23. Have an LLC (zachholman.com)
    35comments
  24. Fragment of oldest known peace treaty found in Turkey (livescience.com)
    8comments
  25. The Cartesian Hand: In-Hand Manipulation with All-Linear Fingers (generalroboticslab.com)
    10comments
  26. A New Experiment Meta-Strategy (chillphysicsenjoyer.substack.com)
    —discuss
  27. Fakecloud: Local AWS cloud emulator for integration tests (fakecloud.dev)
    61comments
  28. My Recent Woodworking Projects (notoriousbfg.com)
    16comments
  29. Video CDs Break Windows Explorer (clydesnotes.blogspot.com)
    38comments
  30. S3 Is the Future, S3 Is the Past (btrblocks.com)
    52comments

Self-Hosting on the Dark Web

73 pointsby 6h agodavid.alvarezrosa.com
24 comments
3h agoHN ↗

Thanks for sharing! Happy to get feedback :)

3h agoHN ↗

Ran a small onion site for a couple years and the nice part is you never touch a public IP or a cert. Downside is onion v3 addresses are impossible to share verbally and the latency makes anything chatty feel broken. Static pages only, honestly.

1h agoHN ↗

You have to keep chattiness low, but a lot of SSR stuff works fine. Dread uses SSR, and even nags you if you have JavaScript enabled.

3h agoHN ↗

Nice thing is you skip port forwarding entirely, which matters a lot if your ISP has you behind CGNAT. Curious how people handle uptime though, since a hidden service going down isn't something you notice until someone tells you.

3h agoHN ↗

What is the benefit of building the same website twice with different hostnames instead of using relative links to content on the same domain?

3h agoHN ↗

Fair point. Very small things like RSS, canonical link or og:url or microformats use absolute URL

To make sure once in the .onion, you never leave the .onion

2h agoHN ↗

Besides accessing your page are random people able to use your server as an exit node? Am I thinking the right thing... I met someone in Switzerland that was hosting anonymous exit nodes to some anonymous network and he said that it was a pain having to explain what was happening to the police.

2h agoHN ↗

That'd be an exit relay, not doing that atm, just in case

2h agoHN ↗

Running a Tor exit node is a manual process. Running a hidden service like a website, or chat server doesn't involve anything like that.

1h agoHN ↗

Exit node are an entirely optional part of the Tor network. If you run a relay or a hidden service you are not forced to participate in the exit node side of things. It's also not recommended to combine these roles because it could have security implications for your hidden service.

2h agoHN ↗

Good call, I'd missed that. Adding it now, thanks.

2h agoHN ↗

Imagine if normal people could install a single normal application and just run a website from a folder. CLI makes it more difficult than hosting a normal website. Typing commands you don't understand doesn't seem all that of a great idea.

1h agoHN ↗

Besides using a separate port, I would also suggest running the hidden service on a non-127.0.0.1 bind address, just in case you ever host something else on that port and forget to disable the hidden service:

HiddenServicePort 80 127.13.37.1:8080

listen 127.13.37.1:8080;

This way, strangers won't be able to connect to a service bound to 127.0.0.1, should you ever decide to re-use the port and forget to disable the hidden service.

You'll also need to use separate ports and/or bind addresses if you host multiple hidden services and don't want people to correlate them - if nginx doesn't match the Host header, it will serve whichever site comes first alphabetically.

1h agoHN ↗

A few more tips.

1. If you want to improve page load speed you need to buy a HTTPS certificate so you are not limited to HTTP/1.1. Multiplexing in HTTP/2 is important for getting sites to load fast.

2. You can set the HiddenServiceExportCircuitID configuration to pass the circuit id to your web server for telemetry or anti abuse purposes. Otherwise your logs will say that all users are coming from the same IP.

https://blog.cloudflare.com/cloudflare-onion-service

8m agoHN ↗

Fascinating, onion services are always encrypted by the tor network but still tunnel "cleartext" http inside that, and there are no CAs that issue free of charge certificates for .onion domains, and therefore there's no free of charge way to get http/2 on onion services without self signing.

Which raises the question: why not just trust self-signed certificates on onion services? From my brief look it seems to be because the Tor project views the primary purposes of HTTPS on onion services to be other things rather than just http/2 support: http/2 isn't even mentioned on their page about https for onion services (https://community.torproject.org/onion-services/advanced/htt...). Unfortunate.

1h agoHN ↗

What I really love about Onion sites is that if they are big enough, performance engineering really becomes Tor-specific. A few examples:

- Making assets embedded as base64 (img src the header logo as base64, all CSS should be inline, etc.).

- Leveraging CSS as much as possible (if you use animations and transitions, use CSS as much as possible for these, avoid JS for them).

- Make sure your website is mostly rendered on the backend. If you're to have JS, your website should work without it.

- Security becomes REALLY fun, as in, avoid XSS, CSRF, SQL Injection attacks and any other injections as much as possible.

As someone summarizes in another comment[0], keep the chattiness as minimal as possible. By chattiness I understand they mean, pack as much data as you can in the same Keep-Alive connection. Avoid making new HTTP requests as much as possible, as each one might get assigned to a new Onion route making things slow.

If you can ship your website to the browser in a single connection, you've won.

I've always been impressed by performance of these big Onion sites, they really push the limits of software engineering creativity, given these constraints and nature of Tor.

--

[0]: https://news.ycombinator.com/item?id=49872320

EDIT: Formatting of bullet points.

50m agoHN ↗

Are these simply good ideas regardless of tor?

22m agoHN ↗

With CDNs of today, they are not so much relevant for the clearnet.