Today I Learned

  • April 14, 2026

    Why browsers have a back button

    Early websites were structured like documents linked together. You would move forward through pages by clicking links.

    The Back button was introduced so users could easily return to the previous page they visited.

    Modern websites are more complex and behave like applications rather than documents. Many use dynamic routing where content changes without reloading the page.

    Despite this shift, the Back button remains essential because users expect to navigate their history easily.

  • April 14, 2026

    Why URLs end with .html

    In the early days of the web, websites were simple files stored on servers. Pages were often actual files like about.html or index.html.

    The .html extension told the server and browser that the file contained HTML markup.

    Modern web frameworks often generate pages dynamically, so the .html part is usually hidden or unnecessary.

    Even when the extension is not visible, many servers still deliver an HTML document behind the scenes

  • April 14, 2026

    DNS

    DNS is the system that translates human friendly website names into the numeric addresses computers use.

    When you type example.com, your device does not know where that site lives. It first asks a DNS server: “What is the IP address for this domain?”

    The DNS server replies with an IP address such as 93.184.216.34. Your browser then connects to that server and loads the website.

    This happens for almost every site you visit, usually in a few milliseconds.

    You can think of DNS as the internet’s phonebook. Instead of remembering phone numbers, we remember names.

    Public DNS

    Most internet providers automatically give you a DNS server, but many people switch to faster public ones.

    Common examples:

    • Cloudflare — 1.1.1.1
    • Google DNS — 8.8.8.8
    • Quad9 — 9.9.9.9

    These often improve speed, reliability, or security.

    Private DNS

    Private DNS encrypts DNS requests so your internet provider cannot easily see what domains you are visiting. Some services also block ads, trackers, or malicious domains.

    Examples:

    • AdGuard DNS (ad blocking)
    • NextDNS (privacy + filtering)
    • Cloudflare DNS with encryption

    Private DNS is commonly enabled on Android devices and modern browsers.

    Learn more

  • April 13, 2026

    Why Undo exists everywhere (Ctrl + Z)

    Undo feels like a basic feature today, but early computers did not have it.

    In early command line systems and text editors, actions were permanent. If you deleted something accidentally, the only option was to manually recreate it.

    The idea of undo began appearing in the 1970s and 1980s in experimental editing systems. One important influence was the work at Xerox PARC, where researchers explored interactive editing environments.

    Undo became widely adopted in software during the personal computer era. Applications like early word processors allowed users to reverse recent actions without losing work.

    Over time it evolved into multi-level undo, where software records a history of changes. Instead of reversing just the last action, programs maintain a stack of operations that can be stepped backward.

    When you press Ctrl+Z or Command+Z, the application typically reverts the most recent change in that history stack.

    This pattern became universal because it dramatically reduces the cost of mistakes. Users feel safer experimenting when they know actions are reversible.

  • April 12, 2026

    Latency vs Bandwidth

    Both latency and bandwidth affect internet performance, but they describe very different things.

    Bandwidth is how much data can move at once.

    Imagine a highway: more lanes means more cars can travel simultaneously.

    Latency is the delay before data starts moving.

    Even an empty highway is frustrating if the traffic light stays red for several seconds.

    Many products focus on bandwidth by compressing images or videos, but latency often matters more for perceived speed.

    Reducing latency is why many companies use:

    • CDNs (servers closer to users)
    • caching
    • edge computing.

    Bandwidth determines how much you can download. Latency determines how quickly things respond.

    Learn more

  • April 10, 2026

    The Endowment Effect

    The endowment effect is the tendency for people to value something more once they feel they own it.

    This was first studied by behavioral economists including Richard Thaler.

    In experiments, participants who were given a mug demanded much more money to sell it than other participants were willing to pay to buy the same mug.

    Nothing about the object changed. Only the feeling of ownership changed.

    Digital products use this effect frequently.

    Free trials, saved preferences, customized dashboards, and partially completed projects all create a sense that the product already belongs to the user.

    Once users invest time configuring something, they become less likely to abandon it.

    The interesting part is that ownership can be psychological, not literal.

  • April 6, 2026

    Why 1px stroke icons sometimes look blurry

    Designers sometimes export a 1px icons/svg but see it appear blurry in the browser.

    This usually happens because of device pixel ratios and subpixel rendering. Modern screens often have more physical pixels than logical pixels used by CSS.

    If a line falls between physical pixel boundaries, the browser blends it across two pixels to display it. That blending makes it look blurry.

    This is common when elements are positioned at fractional pixel values like 0.5px or when scaling layouts.

  • April 1, 2026

    The IKEA effect

    The IKEA Effect describes a psychological bias where people value something more if they helped create it.

    The name comes from IKEA furniture. When you assemble a table yourself, you feel more attached to it than if it came fully built. The effort creates a sense of ownership.

    Products (Digital Applications) use this effect in onboarding and customization. When users set up preferences, create templates, or configure dashboards, they feel like the product belongs to them.

    Examples include Notion workspace setup, Figma design system creation, or customizing a home screen.

    So, what did I learned: Letting users participate in building their experience increases attachment and retention.

    Learn more

  • March 30, 2026

    Internet vs Intranet

    The internet is the global network connecting computers worldwide. It allows anyone to access websites, services, and information.

    An intranet is a private network used inside an organization. Only authorized users within that system can access it.

    Companies often use intranets to share internal documents, training materials, or tools.

    Transportation services sometimes use intranet systems for passengers. For example, trains (Vande Bharat) or airplanes may host a local network with movies, maps, or information accessible through onboard Wi-Fi.

    Because the content is stored locally, it works even without internet access.

  • March 30, 2026

    Loss Aversion

    Loss aversion is a cognitive bias where people feel the pain of losing something more strongly than the pleasure of gaining the same thing.

    Psychologists Daniel Kahneman and Amos Tversky studied this in behavioral economics and found that losses often feel about twice as powerful as gains.

    Free trials often emphasize what you will lose if you cancel. Streak systems warn users they might lose progress. Subscription pages highlight “don’t lose your benefits.”

    Products use this because protecting something we already have is a stronger motivator than gaining something new.

    Learn more

  • March 29, 2026

    How copy + paste works

    Copy + paste seems obvious: copying puts a thing in a box, pasting retrieves the thing from the box. But that’s not what’s happening under the hood.

    When you copy something from an app, the source app registers the possible formats for that data it could provideIt might instantly serialize basic formats (like plain text), but it does not serialize every possible format since to preserve memory and performance.

    When you paste something, the destination app looks at the promises from the source app and requests its preferred format. At this point the source app fulfills the promise and provides the data in the required format.

    This explains why copy + paste works different depending on the destination of the paste event: the destination app (email, spreadsheet, document, etc) chooses the format it wants to receive from the set of available promises.

    macOS does a lot of work under the hood to attempt serialization of common data types when the source app is closed. But there may still be edge cases where if you copy something, close the source app, and then attempt to paste elsewhere, the source can not fulfill its request and the pasted content will be corrupted.

    Copy and paste is not putting things into a box and pulling them out later. It’s brokering promises between apps.

  • March 17, 2026

    HTTP status codes

    HTTP status codes are responses from a server that describe what happened when a browser made a request.

    200 means the request succeeded and the page loaded correctly.

    404 means the server could not find the requested page.

    500 means the server encountered an internal error.

    There are many other codes. For example, 301 means a permanent redirect and 403 means access is forbidden.

    These codes help browsers, developers, and monitoring systems understand how a request was handled.

    Learn more

  • March 20, 2025

    Fisher Yates Shuffle

    While building my Shoot the Serif game, I needed the fonts to appear in a mixed order. Some are serif, some are sans serif.

    At first I tried placing them manually. It was slow and messy.

    Then I found the Fisher Yates shuffle.

    Imagine your fonts are cards on a table.

    Example list:

    Times New Roman, Georgia, Garamond, Arial, Helvetica, Verdana

    Instead of keeping them in order, the algorithm mixes them like a deck of cards.

    It works like this:

    Start from the last item in the list.

    Pick a random item from the remaining ones.

    Swap their positions.

    Move one step backward and repeat.

    By the time you reach the first item, the entire list is shuffled.

    Many programming languages use this idea when implementing shuffle features because it gives every possible order an equal chance.

    • Common uses
    • Fonts in a game
    • Cards in card games
    • Quiz questions
    • Game levels

    Anything that needs fair random ordering.

  • March 12, 2025

    Fuzzy Search

    I learned about something called fuzzy search.

    It helps computers match words even when the spelling is not perfect.

    For example, if you type setings with one “t” missing, the computer can still show settings. Instead of looking for an exact match, it looks for the closest possible match.

    That is why search bars, command palettes, and app launchers often still work even when we mistype.

  • March 12, 2025

    Levenshtein Distance

    Levenshtein Distance sounds complex, but the idea is small.

    It counts how many edits are needed to change one word into another. An edit can be inserting, deleting, or replacing a letter.

    For example, nate → note only needs one change.

    Replace a with o.

    So the distance between the two words is 1.

    Search systems use this idea to detect typos and suggest the closest match.

  • March 12, 2025

    Keyword Mapping

    Keyword mapping is about linking multiple words to the same result.

    For example, typing gear might still show the settings icon. Typing trash might show delete.

    The system simply maps different keywords to the same action or feature.

    It is a small trick, but it makes search feel much smarter.