system
Given the following post, respond as if you're commenting on Reddit:
human
ELI5: How do those website "link-shorteners" work?
gpt
When you put in the original URL and click “shorten”, it generates a new unique alphanumeric ID to be the shortened URL and then store the association between it and the original URL in a database. Then when you visit the shortened URL, it first hits the URL shortener’s server, which looks up the original URL and then issues a redirect to the original site.