Showing posts with label Web Development. Show all posts
November 16, 2026

A Beginner's Guide to HTML Forms




Inputs, labels, buttons, validation, and form states — explained simply.

TL;DR

  • The <form> element gathers user input. Use the action attribute to say where the data goes.
  • <input> is a void element (no closing tag). The type attribute controls what data it collects.
  • Always pair inputs with <label>. Use the for attribute and a matching id for an explicit, accessible link.
  • Buttons come in three types: button, submit, and reset. Prefer the <button> element over <input>.
  • HTML gives you free client-side validation: required, type="email", minlength, and maxlength.
  • Inputs can be in different states — default, focused, disabled, and readonly — each with a clear purpose.

If you're learning front-end development, forms are one of the first things you'll build that actually does something. A login screen, a contact page, a sign-up form — they all start with the same handful of HTML elements. This post walks through the essentials: how forms, labels, and inputs work, the different button types, built-in validation, and the states an input can be in. Everything here is based on what I learned in the freeCodeCamp module on HTML forms, plus a few extra notes that helped it click for me.

What Is an HTML Form?



The <form> element is a container used to gather information from a user — things like names, email addresses, or messages. On its own, a form doesn't collect anything. You fill it with input elements, and the form handles sending their data somewhere when submitted.

<form action="/submit-endpoint">
  <!-- input elements go here -->
</form>

The action attribute tells the browser where to send the form data when the user submits it. In real projects, that URL points to a server endpoint that processes the data. While learning, you can leave action empty or point it at a placeholder.

Collecting Input with <input> and <label>



The input element

To actually collect information, you use the <input> element. It's a void element, which means it has no closing tag and can't contain child content.

<form action="">
  <input type="text" />
</form>

The type attribute defines what kind of data the input expects. type="text" gives you a plain text field. Other common values include email, password, number, checkbox, radio, and date. Choosing the right type matters — it changes how the field behaves, what keyboard shows up on mobile, and what built-in validation you get for free.

Labels: implicit vs explicit association

A label tells the user what a field is for. There are two ways to connect a label to an input.

Implicit association happens when you nest the input inside the label:

<form action="">
  <label>
    Full Name:
    <input type="text" />
  </label>
</form>

Explicit association uses the for attribute on the label and a matching id on the input. This is the approach most accessibility tools and screen readers prefer, and it's the one I'd recommend getting comfortable with:

<form action="">
  <label for="email">Email Address:</label>
  <input type="email" id="email" />
</form>

When you use explicit association, the for value and the id value must match exactly. In the example above, both are set to email.

Quick tip: the id must be unique on the page — it identifies one specific element. The name attribute, on the other hand, is what gets sent to the server as the field's label when the form is submitted. They often have the same value, but they serve different purposes. Forgetting the name attribute is one of the most common reasons a form "works" in the browser but arrives at the server empty.

The placeholder attribute

If you want to give users a hint about the expected format, use the placeholder attribute. The placeholder text appears inside the field when it's empty and disappears as soon as the user starts typing.

<form action="">
  <label for="email">Email Address:</label>
  <input type="email" id="email" placeholder="example@email.com" />
</form>

Keep placeholders short and useful — think "example format," not instructions. A placeholder is no substitute for a proper label, since it disappears the moment the user starts typing and can be easy to forget.

Buttons: Types and When to Use Them



The <button> element performs an action when activated. At its simplest, it looks like this:

<button>Start Game</button>

The type attribute controls what the button does when clicked. There are three possible values.

1. type="button"

A plain button that does nothing on its own. You wire it up with JavaScript to do whatever you want — open a modal, toggle a menu, show an alert.

<button type="button">Show Alert</button>

2. type="submit"

Submits the form it belongs to. When the user clicks it, the form's data is sent to the URL set in the action attribute.

<form action="">
  <label for="email">Email address:</label>
  <input type="email" id="email" name="email" />
  <button type="submit">Submit form</button>
</form>

3. type="reset"

Clears every field in the form back to its default value.

<form action="">
  <label for="email">Email address:</label>
  <input type="email" id="email" name="email" />
  <button type="reset">Reset form</button>
  <button type="submit">Submit form</button>
</form>

Honestly, reset buttons are usually a bad idea. Users click them by accident and lose everything they just typed. Most modern forms skip them entirely.

Using <input> as a button

You can also create buttons using the <input> element with type="submit", type="reset", or type="button". The button text comes from the value attribute:

<input type="button" value="Start Game" />

input vs. button: which should you use?

Since <input> is a void element, it can't have child content — you can only set its text through the value attribute. The <button> element is more flexible: you can put text, images, icons, or any other HTML inside it. In most cases, <button> is the better choice. Reach for <input type="button"> mostly when you're matching older code or working with a framework that expects it.

Client-Side Form Validation



Validation is how you make sure users fill out the form correctly before the data is sent anywhere. HTML gives you a surprising amount of validation for free, right in the browser — no JavaScript required.

It's worth knowing the two layers of validation:

  • Client-side validation runs in the user's browser. It's the first line of defense — fast, friendly, and helpful for catching typos.
  • Server-side validation runs on your server after the data is submitted. It's the real security boundary, because a malicious user can always bypass client-side checks by editing the HTML or sending a request directly.

Client-side validation improves the experience. Server-side validation keeps your app safe. You need both.

The required attribute

Add required to an input to tell the browser the field can't be left empty. If the user tries to submit without filling it in, the browser shows a built-in message and blocks the submission.

<form action="">
  <label for="email">Email Address (Required field):</label>
  <input required type="email" name="email" id="email" />
  <button type="submit">Submit Form</button>
</form>

Built-in email validation

Using type="email" gives you basic format checking for free. If a user types something that doesn't look like an email (say, abc), the browser will warn them. Note that this check is intentionally loose — it mostly just looks for an @ and a domain. Real, robust email validation happens on the server.

minlength and maxlength

These attributes set the minimum and maximum number of characters the field will accept. If the input is too short or too long, the browser blocks submission.

<form action="">
  <label for="email">Email Address (Required field):</label>
  <input
    required
    type="email"
    name="email"
    id="email"
    minlength="4"
    maxlength="64"
  />
  <button type="submit">Submit Form</button>
</form>

Form States: Why They Matter

Inputs can be in different states, and each one tells the user something useful.

  • Default state: what the input looks like when the page first loads — usually just an empty field.
  • Focused state: when the user clicks the field or reaches it with the Tab key. Most browsers show a highlighted outline. You can customize this with CSS, but never remove it entirely — keyboard users rely on it.
  • Disabled state: the input can't be focused, edited, or submitted. Use it for fields that aren't relevant right now (for example, a "confirm password" field before the first password is entered).
    <input disabled type="email" name="email" id="email" />
  • Readonly state: the value is shown but can't be edited. Unlike disabled, a readonly input can still be focused and its value is still submitted with the form. The value attribute sets the displayed text.
    <input
      readonly
      type="email"
      name="email"
      id="email"
      value="example@email.com"
    />

The key difference between disabled and readonly: a readonly field can be focused and its data is sent to the server; a disabled field can't be focused and its data is excluded from submission. Choose based on what you want to happen with the value.

Paying attention to states is what makes a form feel polished. Clear focus styles guide keyboard users. Disabled fields prevent invalid actions. Readonly fields show data the user shouldn't change but you still need. Small details, big difference.

Best Practices for Beginners

  • Always label your inputs. Even if the design hides the label visually, keep it in the HTML for screen readers.
  • Prefer explicit association. Use for on the label and a matching id on the input.
  • Don't forget the name attribute. Without it, the field's value won't be sent to the server.
  • Pick the right input type. type="email", type="number", type="date" — each gives you better UX and free validation.
  • Avoid reset buttons. They cause more accidental data loss than they're worth.
  • Use <button> over <input> for buttons. More flexible, easier to style.
  • Always validate on the server too. Client-side validation is for usability, not security.
  • Keep placeholders as hints, not labels. They disappear when typing, so don't rely on them for important context.

Further Reading


HTML forms aren't flashy, but they're at the heart of almost everything users do on the web. Get comfortable with <form>, <input>, <label>, and <button>, understand the built-in validation, and you'll be able to build most of the forms you encounter as a beginner. The next step is learning how to handle the data on the server — but that's a post for another day.

Written as part of my freeCodeCamp journey to becoming a full-stack developer. Got feedback or a form gotcha I should know about? Drop it in the comments.

November 03, 2026

Nuanced HTML Elements



Today's stop on my freeCodeCamp full-stack journey: nuanced HTML elements. Here's what surprised me — some HTML elements look exactly the same in the browser, but mean completely different things underneath. One pair quietly says "notice this," while the other firmly says "this really matters." That hidden meaning is what developers call semantics: markup that describes what text is, not just how it looks.

In this post I'll walk you through the two element pairs I studied today — plus a bonus list type you may not have met yet — in plain, beginner-friendly English. No fluff, promise.

i vs. em: A Different Vibe or Real Emphasis?



The <i> element is officially called the idiomatic text element. Its original job was purely visual: display text in italics. HTML5 gave it a more meaningful role, though. Today it marks text that is somehow different from the words around it — an alternative voice or mood, an idiomatic phrase from another language, a technical term, or a thought.

Here's a classic example, using <i> for a French phrase:

<p>There is a certain <i lang="fr">je ne sais quoi</i> in the air.</p>
In the browserThere is a certain je ne sais quoi in the air.

That lang="fr" attribute tells the browser the wrapped words are in French — helpful for screen readers and translation tools. And notice what <i> doesn't say: it doesn't claim the text is important. It only says "this bit is somehow different."

When the words genuinely matter — when stressing them changes the meaning of the sentence — use the emphasis element, <em>, instead:

<p>Never give up on <em>your</em> dreams.</p>
In the browserNever give up on your dreams.

Say it out loud: "Never give up on your dreams" means something different from "Never give up on your dreams." That's the shift <em> captures, and it's why it's usually limited to just a word or two.

Visually, the two elements are twins — both render as italics. The difference happens behind the scenes, where <em> carries meaning that browsers, screen readers, and search engines can pick up. One more thing: if you want italics purely for looks and the text has no special purpose, use neither element. Style it with CSS instead (font-style: italic).

b vs. strong: Attention or Importance?



Same story, bolder font. The <b> element — the "bring attention to" element — highlights text the reader's eye should catch, like keywords in a summary or product names in a review:

<p>
  We tested several products, including the <b>SuperSound 3000</b> for
  audio quality, the <b>QuickCharge Pro</b> for fast charging, and the
  <b>EcoClean Vacuum</b> for cleaning. The first two performed well, but
  the <b>EcoClean Vacuum</b> did not meet expectations.
</p>
In the browserWe tested several products, including the SuperSound 3000 for audio quality, the QuickCharge Pro for fast charging, and the EcoClean Vacuum for cleaning. The first two performed well, but the EcoClean Vacuum did not meet expectations.

The product names now stand out instantly. But just like <i>, the <b> element doesn't imply a higher level of importance — the names are simply easy to spot.

When something is truly important — crucial or urgent — the semantic element to reach for is <strong>:

<p><strong>Warning:</strong> This product may cause allergic reactions.</p>
In the browserWarning: This product may cause allergic reactions.

Both elements render as bold by default, but their meanings are quite different. <b> draws attention; <strong> conveys importance and urgency — you can almost hear the serious tone. That's the main difference between them.

So how do you choose? Think about the text's purpose within the surrounding content. If it just needs to be noticeable, use <b>. If it's genuinely important, or it's a warning people must not miss, use <strong>. And if you want bold purely for visual reasons, that's a job for CSS (font-weight: bold), not either element.

Wait — if they look identical, why bother?

Because not everyone experiences a page with their eyes. Screen readers can put vocal stress on <em> text and treat <strong> as a serious flag, so someone listening to your page hears the same emphasis you see. Search engines and other machines read the meaning too. A little history explains the confusion: in the HTML 4 days, <i> and <b> were pure style tags (italic and bold). When CSS took over styling, HTML5 redefined them with meaning instead of retiring them. Old look, new job.

The Cheat Sheet

Here are all four elements side by side:

ElementLooks likeWhat it really meansGood for
<i>Italic"This text is somehow different"Foreign phrases, technical terms, thoughts
<em>Italic"This really matters" — real emphasisA word or two that change the sentence's meaning
<b>Bold"Look here" — attention onlyKeywords, product names
<strong>Bold"This is important or urgent"Warnings, crucial notes

Quick way to remember

  • <em> = it matters. <i> = just a different vibe.
  • <strong> = it's serious. <b> = just noticeable.

Description Lists: dl, dt, and dd



Description lists are perfect when information comes in pairs — a term plus its related details. A glossary is the classic example, working just like a real dictionary where each word comes with its definition.

You need three elements to build one, and each has a single job:

  • <dl> (description list) — the container that wraps the entire list
  • <dt> (description term) — one for each term
  • <dd> (description details) — the details attached to the term right above it

Here's a small glossary with three entries:

<dl>
  <dt>HTML</dt>
  <dd>HyperText Markup Language</dd>
  <dt>CSS</dt>
  <dd>Cascading Style Sheets</dd>
  <dt>JS</dt>
  <dd>JavaScript</dd>
</dl>
In the browser
HTML
HyperText Markup Language
CSS
Cascading Style Sheets
JS
JavaScript

Each term appears with its description slightly indented to the right — a clean, readable pair. The details don't have to be definitions, either; they can be any information related to the term.

But glossaries are just the beginning. A recipe works exactly the same way, with the ingredient as the term and the amount as the details:

<dl>
  <dt>Flour</dt>
  <dd>2 cups</dd>
  <dt>Sugar</dt>
  <dd>1/2 cup</dd>
</dl>

In the browser you'd see the ingredients aligned to the left and the measurements indented underneath them. The same <dt> + <dd> pattern simply repeats for as many entries as you need.

Once you start seeing information as key–value pairs, description lists are suddenly everywhere: product specifications, FAQs (question as the term, answer as the details), contact information, and metadata. Whenever one piece of information acts as the label and the other provides related information, a description list is usually the cleanest way to mark it up.

So, that's today's lesson: <em> and <strong> carry real weight, <i> and <b> are gentle "notice this" nudges, and <dl> turns pairs of information into clean, semantic markup.

Further reading: the MDN reference pages for <i>, <em>, <b>, <strong>, and <dl>.

October 31, 2026

Semantic HTML, Explained Simply ( What I Learned Today )



Today's lesson on my road to becoming a fullstack developer was all about semantic HTML, courtesy of freeCodeCamp.

Ttoday I learned that the tags themselves carry meaning and using them carelessly has real consequences for accessibility, search rankings, and devex

First, What Does "Semantic" Even Mean?



Semantics means: the meaning of words or phrases in a language. And since HTML is a language too, its elements have their own semantic meaning.

The easiest way to picture this is to think of your HTML document like a text document. A text document has headings, images, bold text, and other formatting and HTML has elements that represent each of those.

The semantic meaning of an element is the special information that element conveys. A p element, for example, says "this is a paragraph of text":

<p>
  Let me tell you about my fantastic holiday in Paris.
  I saw the impressive Eiffel Tower up close!
</p>

Most elements have semantic meaning. The div element is one of the very few that doesn't — it's just an empty, meaningless box. Using divs isn't a crime  but as I learned today, leaning on them for everything is a habit worth breaking.

Why Should You Care? Three Big Reasons



Proper semantic HTML isn't about being pedantic — it comes with three very practical benefits:

  1. It makes your site work better for people using assistive technology. Screen readers read pages out loud, and they rely on meaningful elements to understand and describe what's on the page. 
  2. It can improve your search rankings. This is called search engine optimization, or SEO
  3. It makes development way less painful. Instead of sifting through a pile of divs to find your navigation bar, you can edit the nav element directly and know exactly what you're changing.

Heading Hierarchy



The most important part of building a structural hierarchy is using heading elements properly.  h1, h2, h3, and so on. That number is the heading's level, and much like in a text document, you don't want to use them in the wrong order.

  • h1 is your top-level heading. You'll rarely have more than one per page, and it should typically come before all of your content.
  • h2 is your subheading. It always comes after the h1 sometimes after a bit of introductory text, and unlike h1, you can have multiple h2s on a page. You'll often use them to split your content into sections.
  • h3 comes after an h2. You should never skip directly from h1 to h3 — but you can have multiple headings at the same level.

For example, this structure is correct:

<section>
  <h1>freeCodeCamp</h1>
  <h2>Learn Front-End Development</h2>
  <h2>Learn Back-End Development</h2>
</section>

using h1 just because you want big text is not preferred. You should use CSS to do that.

Why this matters:

  • Accessibility screen readers rely on the structure of a page to decide how to parse and announce it.
  • SEO: search engines use automation to parse your page. So bad structure results in bad ranking
  • Validity: depending on how incorrect your structure is, your HTML may not even be technically valid.

Presentational HTML: The Old Way (deprecated method)



Presentational HTML focuses on the appearance and style of content. In the early days of the web, developers used elements like center, big, and font. Modern web development has moved on, and you shouldn't use these types of elements anymore. For example:

The font element was used to set the font size and color of text:

<font size="5" color="blue">This text is blue and large.</font>

Note: the size attribute ranges from 1 to 7 

The center element was used to center content horizontally within its container:

<center>
  This text is centered.
  <p>HTML is awesome.</p>
</center>

And the big element made text one level bigger than the surrounding text:

<p>
  This text has a normal font size.
  <big>This text is larger.</big>
  Some other text.
</p>

As you might have noticed, we don't need these anymore because we have a better tool to do this in the form of CSS.

Semantic HTML: The Modern Way



Semantic HTML is the recommended practice today. Instead of describing how content should look, it describes what the content is. That makes it much easier to read, understand, and maintain.

It also helps the machines that read your page: search engines can easily understand your website, and screen readers get the semantic information they need to describe what's on it.

A few examples:

  • header — for defining the header of the document or a section
  • nav — for sections with navigation links
  • section — for grouping related information
  • figure — for illustrations and diagrams

Here's a header element containing a navigation section:

<header>
  <nav>
    <a href="#">Home</a>
    <a href="#">About</a>
    <a href="#">Contact</a>
  </nav>
</header>

The purpose of each element is right there in the name — the elements clearly show their role within the structure.

A Little Cheat Sheet

ElementWhat it means
pA paragraph of text
h1 – h6Headings in order of importance — h1 is the top level
headerThe header of the document or a section
navA section with navigation links
sectionA grouping of related information
figureAn illustration or diagram
divNothing at all — a generic container with no semantic meaning

My Takeaways from Today's Lesson

A few things I want to remember from today:

  • HTML is for meaning, CSS is for looks. The moment I stopped asking "which tag makes this look right?" and started asking "what is this content?", the whole thing clicked.
  • Accessibility isn't an afterthought. Someone using a screen reader experiences my page through the tags I choose. That alone is reason enough to do this properly.
  • Skipping heading levels is more than a style problem. It actively confuses screen reader users and search engines — it's not just untidy.
  • "It works" isn't the same as "it's right." Deprecated elements still render in browsers, but that doesn't make them a good idea.
  • Personal mission: stop using div for everything. If something is a navigation bar, it deserves to be a nav.
October 15, 2026

Optimzing Images for the Web: Size, Licensing and SVGs



Images make a website feel alive, but they can also slow it down and cause legal trouble if you handle them carelessly. Today, I'll share what I learned about images for use on web.

Optimizing Media Assets

Three things matter when using images on a web page: size, format and compression.

1. Size

If you style an image to display at 640X480 (640px wide & 480 px tall), we should use an image file of the same size. If we use a 1920X1080 image file for this small display space the users are forced to download data that they'll never see. A smaller resolution means smaller file, which in turn means faster page.



2. Format

PNG and JPG are the most common formats for images. But these are no longer the best option for web use. For web, WEBP or AVIF are the most optimized (but may cause compatibility issues for some older browsers)

3. Compression

We can run compression algorithms on our images to shrink the image size. But not all compressions run the same way

  • Lossless formats like PNGs can be compressed without any quality loss, because the original data can be reconstructed perfectly. Using tools like PNGCRUSH it's very easily doable
  • Lossy formats like JPGs lose quality from compression though

Image Licenses
Images are intellectual property, and most of the time they're protected by copyright. By default they're all rights reserved, so we can't just use any image we want from the internet in our page. To use these images we need to:



  • Get written permission from the copyright holder.
  • or Purchase a license from the creator
  • or Use the image in a way that falls under fair use.
Fair use is a tricky one. We must be both limited and transformative in our use case.

Then there are Public Domain images. These images have no copyright attached and can be used freely. Images released under Creative Commons 0 are treated as public domain. Sites like Pixabay, Unsplash etc. have images which are free to use. 

SVGs
PNG and JPG are raster formats: they store color value on every pixel. This means they don't upscale well and get pixalated or blurry.




On the other hand, SVGs (scalable vector graphic) work differently. It stores color values as paths and equations that plot points, lines and curves, so it can be scaled to any size with no loss in quality.

SVG store their data in XML, so we can write SVGs directly inside our HTML code using the svg element

-----
<svg viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg">
  <circle cx="50" cy="50" r="45" fill="yellow" />
  <circle cx="35" cy="40" r="5" fill="black" />
  <circle cx="65" cy="40" r="5" fill="black" />
  <path d="M30 65 Q50 85 70 65" stroke="black" stroke-width="3" fill="none" />
</svg>
-----




Basic syntax
svg: The container housing all the elements. Everything else goes inside it.
circle: Used to draw a circle
path: draws curves or lines

Best place to use SVGs: Icons, Logos. Font awesome is the most popular icon library which also use SVGs.

There we have it. Basics of using images on the web.

Thank you for reading!!!
September 23, 2026

Open Graph Tags & Meta Descriptions: The SEO Basics Nobody Explains Well



If you've ever shared a link on Facebook or LinkedIn and watched a clean preview card pop up — complete with an image, title, and description — you've seen Open Graph tags in action. And if you've ever looked at Google search results and noticed that little snippet of text under each blue link, that's a meta description doing its job.

Here's a breakdown of both, why they matter, and how they tie into SEO.

What Are Open Graph Tags?

Open Graph (OG) tags are a set of meta elements you place in your HTML <head> section. They control how your page looks when it's shared on social platforms — Facebook, LinkedIn, and others that support the protocol. Without them, a shared link often looks bare or pulls in random, unflattering content from your page.

The four properties worth prioritizing:

og:title — the headline shown in the preview card.

html
<meta property="og:title" content="10 Habits of Highly Productive Developers" />

og:type — tells platforms what kind of content this is (website, article, video, etc.).

html
<meta property="og:type" content="article" />

og:image — the thumbnail shown alongside the title. Facebook recommends at least 1200×630px for high-res displays, with 600×315px as the bare minimum.

html
<meta property="og:image" content="https://example.com/images/productivity-cover.jpg" />

og:url — the canonical link, so shares always point back to the "real" URL rather than a duplicate or tracking link.

html
<meta property="og:url" content="https://example.com/blog/productivity-habits" />

There are more you can add — og:description, og:audio, og:video, og:locale — but title, type, image, and url form the core set.

How does this connect to SEO?

Open Graph tags don't directly move the needle on Google rankings — search engines aren't reading your OG tags to decide where to place you in results. The connection is indirect but real: a strong preview card makes people more likely to click when your content shows up in their social feed. More clicks and engagement signal to platforms (and indirectly to search engines tracking traffic and engagement patterns) that your content is worth surfacing. Good OG tags are less "SEO hack" and more "don't sabotage yourself by looking untrustworthy or broken when someone shares your link."

What Is a Meta Description?

The meta description is a short summary of a page, also set via a meta tag — but this one is aimed at search engines and searchers, not social platforms.

html
<meta
  name="description"
  content="A no-fluff guide to building a daily routine that actually improves focus and output."
/>

Setting name="description" (instead of property, which OG tags use) tells browsers and search engines exactly what this data represents.

This description doesn't appear anywhere on the visible page itself — its main stage is the search engine results page (SERP), where it shows up as the snippet under your title and URL:

example.com › blog › productivity-habits
10 Habits of Highly Productive Developers
A no-fluff guide to building a daily routine that actually improves 
focus and output. Includes a free weekly planning template...

That snippet is often the deciding factor in whether someone clicks your result or the one above/below it. Keep it short and to the point — search engines will truncate long descriptions anyway, usually somewhere around 150-160 characters, so anything past that risks getting cut off mid-sentence.

Does it affect rankings?

Not directly. Google has been clear that meta descriptions aren't a ranking factor. But indirectly, a compelling description increases your click-through rate (CTR), and traffic/engagement patterns are things search engines do pay attention to over time. So: not a ranking signal itself, but a lever that can drive more of the traffic that does influence your standing.

Quick Recap (for future self)

TagAttributePurposeDirect SEO impact?
og:titlepropertyHeadline on social sharesNo — indirect via CTR
og:typepropertyContent type (article, website, etc.)No
og:imagepropertyPreview thumbnail (1200×630 ideal)No — indirect via CTR
og:urlpropertyCanonical share linkNo
meta descriptionnameSearch result snippetNo — indirect via CTR


The one-sentence version: Open Graph tags make your links look good when shared socially, meta descriptions make your links look good in search results, and neither one directly boosts your ranking — but both drive the clicks that can.

May 21, 2025

Zed: A Vim User's Perspective – Is This My New Daily Driver?

 

 


 Zed is a recent release and is picking up steam. Zed is made by the makers of Atom and Tree-sitter. It's an exceptionally fast, collaborative editor. It's designed to be fast and aims to provide a next-generation editing experience with the capabilities and extensibility of a quality editor. It comes with reasonable defaults and is highly customizable.

  Vim (or Neovim, I should say, as that is what it is for me) has been more than a code editor for some years now; it has been an extension of myself, a precision tool for crafting code. The modal editing, the immediate navigation, the pure productivity – you can't help but wonder once you "get" Vim how you ever did otherwise.

So, when a new editor pops up on the horizon, particularly one with "Vim-inspired" features, my attention is piqued. 

Meet Zed. Created by the masterminds behind Atom and Tree-sitter, Zed offers up a next-generation, high-performance, and collaborative editing experience. But can it really win over an old hand like me who's spent years using Vim?

After spending a some time with Zed, I'm seriously impressed, and bold me if I say, a little stoked. Now, here's why Zed, as the new kid on the block that it is, is so familiar and powerful to a Vim power user:

 

The "Vim-Inspired" Part: It's Not Just a Gimmick, It's the Core 

The biggest hurdle for any Vim user to overcome is muscle memory. Our fingers are trained in `hjkl`, `w`, `b`, `dd`, `yy`, `p`, and all the other Vim keystrokes that result in effortless editing. Zed understands this on a deep level. 

The moment I started using it, the underlying editing gestures were hauntingly familiar. It's not just vanilla keybindings; it's the philosophy. The modal editing model is present, and while it's not a 1:1 translation of Neovim's copious set of modes and operators, it's almost identical. I tended to fall into my Vim habits by default, and for the most part, Zed is a good sport about it.

Out-of-the-Box Genius: LSP & Autocomplete Made Easy

This is where Zed excels and addresses one of the most common annoyances for Vim enthusiasts: 

Language Server Protocol (LSP) and autocomplete. With Neovim, setting up LSP so it's working flawlessly requires a lot of setup, plugin hunting, and often debugging. A rite of passage for some, but definitely time-consuming nonetheless.

 Zed, on the other hand, just *gets it done*. I opened a Rust project, and bang – intelligent autocompletion, go-to-definition, reference lookups, and error highlighting were all present, straight away. No `init.lua` trickery, no `:LspInstall`, no `Mason` setup. This "zero-config" LSP experience is revolutionary and an incredible productivity benefit out of the box. For those who desire immediate productivity and reduced setup overhead, this is a huge win.

Customization: Your Vimrc, Brought to Life

The mark of an truly fantastic editor for the Vim user is how much it can be customized. We spend hours, if not days, fiddling with our `init.vim` or `init.lua` to get the ideal code environment for ourselves. Zed understands this desire for customization intimately.

One of the strengths of Zed is its very flexible keybinding system. I could import *most* of my own custom Neovim keybindings with little effort into Zed. This is not about just remapping basic commands; it can support elaborate key sequences and context-dependent bindings, mimicking the behavior of Neovim's `leader` key and even more advanced mappings.

For Example: 

 

I'd confidently say that you can configure Zed to get approximately **90% of your Neovim workflow** done. That's a bold claim, but my experience tells me it is true. From personalized leader mappings to certain actions run on a sequence of keys, Zed's configurations are robust enough to truly feel like "my editor."

Beyond Vim: Modern Features That Matter

While its Vim-like soul is a big draw, Zed is not a Vim clone. It boasts a wealth of modern features that are totally worth it:

  • Performance: It's fast. There's no wait to startup, and even large files and complex projects respond immediately.
  • Collaboration: Built-in collaborative editing is a great added benefit, especially for pair programming or team projects.
  • UI/UX: A clean, simple interface that is aesthetically pleasing without being distracting

The Verdict (So Far): A Strong Contender

A committed Neovim user, I entered Zed with an appropriately healthy skepticism. But after seeing what it can do, I'm really impressed. It packs an impressive punch combining the efficiency of Vim with contemporary editor niceties, most notably its unobtrusive LSP integration.
 

Will it supplant Neovim for all? Not immediately, perhaps. There will always be some esoteric plugins or very specialized setups that Vim does better due to its sheer age and extensive ecosystem. But for those who value:

  • Minimalistic setup for robust functionality (especially LSP)
  • A richly customizable keybinding system that respects Vim muscle memory
  • Blazing performance and a modern UI
  • Native collaboration

then Zed is a seriously strong competitor. It's becoming a daily driver for me now, and I strongly recommend any other Vim user to try it in good earnest. You might end up with your new favorite editor.

What's your impression of Zed? Have you tried it as a Vim user? Please share with us in the comments below!

My zed config: https://github.com/M4H1-4B1R/dotfiles/tree/main/zed/.config/zed