Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Probably a good chance to inject this here:

You can build your own private URL shortener with AWS Lambda, for a dozen cents a month [0]. I've made some modification to it so that it supports customized short name, but the changes are trivial to implement. You could (should?) also probably consider a short domain name to pair with it, but those are also cheap ($10/yr, perhaps depend on the TLD).

[0]: https://aws.amazon.com/blogs/compute/build-a-serverless-priv...



URL Shorteners break the Internet[0] (2009)

With Google Or Twitter, at least, they have some semblance of permanence, but with everyone hosting their own private shortener, will just lead to madness.

[0]: https://blog.codinghorror.com/url-shorteners-destroying-the-...


Since then, URLs have even less to do with any real underlying directory structure.

What's another level of indirection between the browser and your CDN, your reverse proxy, your cache and your web framework?


Do u the source for custom-short-name on GitHub somewhere?


How fast is this?


At it's core, this URL shortener is just S3 redirect objects [0], behind a cloudfront CDN. So by "fast", you probably mean one of these things:

1) User clicking on a URL: the latency of this action is mostly determined by the latency of cloudfront, which is pretty fast [1]. (Except in the case of a first-click when cloudfront has to do a pull from S3, which is also not bad [1])

2) Creation of a new short URL: this action is the execution of a lambda function, which in my experience is ~1s in cold-start scenarios, and near instant otherwise.

[0]: https://docs.aws.amazon.com/AmazonS3/latest/dev/how-to-page-...

[1]: https://www.quora.com/What-are-typical-latencies-for-static-...


Talk about over engineering: spin up your own URL shortener using Lambda.


It’s really just a few clicks with CloudFormation




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: