mrkeyoor.comAsk

bigskysoftware/htmxtested 26 Oct 2026commit fa978b2

htmx review

Use htmx when your server already renders the forms and content that users update.

  • README install 1.6 s
  • README snippet failed
13 sto install
  • 988 KB on disk
  • 0 dependencies
Webevaluationupdated 22 Nov 2026
+2stars / 7d

htmx is a JavaScript library that lets HTML attributes request server-rendered content and update selected parts of a page. Its documented request-and-swap model suits applications whose server already renders the views.

Verdict

Use htmx when your server already renders the forms and content that users update. Our October repository run completed installation in 13 seconds and tests in 81 seconds; the November quick-start recipe failed before exercising the HTML interaction. Teams whose main requirement is extensive shared browser state should evaluate a client framework before choosing this request-and-swap model. Compare Turbo for scoped navigation and Unpoly for targeted updates from full-page responses.

htmx infographic: update selected parts of a page with server-rendered content, plus our test result and who it suits
Tested 22 November 2026: the README snippet failed. Before that: 26 Oct: source install 13 s; npm install took 1.6 s.

We ran it

Lab card: what happened when we ran htmx
Lab card from our sandbox run
Screenshot of htmx (htmx.org)
htmx.org
Install✓ · 13s502 packages · 171 MB
Buildn/ano build script
Tests✓ · 81sran, no count parsed
Known vulns00 critical · 0 high · 0 moderate · 0 low (npm audit)
Repo639 files~57,804 lines of source · 94.9 MB · 1 CI workflows · tests dir

Answers from our run

Does htmx build from source?

Dependencies installed in 13 seconds (502 packages), and the project has no separate build step. We cloned commit fa978b2 into a clean Debian container with 3 CPUs and no project-specific setup.

Do htmx's tests pass?

Yes. The project's own test command exited successfully in 81 seconds, although its output did not expose an individual test count.

Does htmx have known vulnerabilities in its dependencies?

npm audit found none in the dependency tree at the time of our run.

Who should not use htmx?

Teams choosing primarily for extensive shared browser state: RFC Hub's author anticipates changing frameworks if screen state grows too complex.

What are the alternatives to htmx?

React, Turbo, Unpoly. Use htmx when your server already renders the forms and content that users update.

Setup4/5In our 2026-11-22 run it installed as the README says in 1.6 s; the README gave no task we could run as written.Editor’s note: Repository installation and tests succeeded, but the quick-start recipe stopped before a browser interaction. Application setup ease has no separate assessment.
Docs4/5The README has an install section (“quick start”) and usage in the same section; we did not run its quickstart ourselves.Editor’s note: The README and reference extracts document requests and HTML responses, but they do not establish documentation-wide accuracy or coverage.
Community5/5Last push on 2026-11-20, 49,654 stars and maintainers answered or closed 10 of the 10 most-discussed issues we sampled.Editor’s note: Named application reports and issue exchanges document participation without measuring support capacity or response times.
Maturity5/5Latest release v4.0.2 on 2026-11-18, repository created 2020-04-13 and its test suite passed in our sandbox.Editor’s note: Dated repository checks and release metadata do not assess production reliability, browser coverage or application migrations.

How we score

Discussed on

  1. hnHtmx changes license to Zero-Clause BSD213 points
  2. hnHtmx 2.0.4 Released196 points
  3. hnHtmx: High Power Tools for HTML74 points
  4. hnHtmx become 0 clause BSD-licensed35 points
  5. hnHtmx 2.0 Released15 points

Who it’s for

Backend developers adding partial updates to server-rendered forms, lists and search results.
Go developers who want HTML templates to remain responsible for views.
Teams prepared to design response headers, error fragments and navigation behavior alongside the HTML.

Who it’s NOT for

Teams choosing primarily for extensive shared browser state: RFC Hub's author anticipates changing frameworks if screen state grows too complex.
Projects requiring IE11 while following 2.x examples: the documentation assigns IE11 support to version 1.
Applications expecting ordinary hx-get requests to display chunked responses incrementally: issue #1911 reports waiting for the complete response.

Setup reality

Our October 26, 2026 run at fa978b2 installed successfully in 13 seconds and passed its test step in 81 seconds. It recorded 502 dependencies and 171 MB on disk. The build was skipped because there was no build script or target. npm audit reported 0 known vulnerabilities.

Application use needs a browser script and a backend endpoint returning HTML. The README demonstrates a button that posts to /clicked and replaces itself with the response. It names the npm package htmx.org and warns against the old htmx package.

The October sandbox configuration was 3 CPUs, 8 GB RAM and image label lab-node:22. The separate November 22 quick-start recipe recorded htmx.org package version 2.0.11, then failed its snippet step because it looked for JavaScript or TypeScript code in a README whose interaction example is HTML.

Short answer

htmx lets HTML attributes request server-rendered content and replace a selected part of a page. Choose it when your server already renders forms, search results or record-management screens. Teams whose main requirement is extensive shared browser state should evaluate a client framework first. Thomas Hunter II chose htmx for RFC Hub's proposal-management work and Vue for Map Buddy's interactive mobile interface, describing two applications with different requirements.

Our run completed installation in 13 seconds and tests in 81 seconds on October 26, 2026. A separate November quick-start recipe failed while looking for a JavaScript or TypeScript snippet in the README. These outcomes describe different tasks: repository checks completed in October, while the November automation stopped before exercising the README's HTML button. The adoption question is whether returning HTML fits the interactions your application needs.

What people use htmx for

RFC Hub, Contexte's search interface and the Go examples show reported uses for proposal management, faceted search and asynchronous loading. Their authors describe specific applications rather than a single architecture suitable for every interface. The accounts also expose the backend work behind the attributes: rendering responses, choosing update targets and deciding how navigation and errors should behave.

Who used it What they built What they reported
Thomas Hunter II RFC Hub, a technical proposal application using EJS templates About 200 lines of application-specific browser JavaScript, plus difficulties with response headers and silent server errors
David-Guillot at Contexte Faceted search for French political editorial content Successful results and facet updates, alongside a reproducible browser-history failure
anthdm on X Asynchronous loading with Go, htmx and Templ Loading computationally expensive data without writing application JavaScript
Hi_Mrinal on X A workflow-engine assessment adapted into a news and development-resource aggregator Simple tasks using Go, Redis, gRPC, htmx and Tailwind CSS

Hunter's RFC Hub account describes organizations, proposals, tags, comments and review status. He renders nearly all HTML through EJS and uses htmx for actions such as adding reviewers and publishing proposals. Ordinary browser JavaScript still handles parts of the interface. The useful distinction is responsibility: the server produces the views, request attributes connect interactions to endpoints, and application JavaScript handles additional local behavior.

Contexte's reported search interface updates both results and facets. Its issue report also gives a repeated navigation sequence that restores the wrong content. The Go posts describe smaller interactions and workflow tasks. Hi_Mrinal presents deployment pipelines as a possible future use of the workflow engine, while the described implementation handles simple tasks and aggregates news and development resources.

What happened when we ran it

Our November 22 quick-start run at 51c3e67bcedc failed its snippet step because the README has no JavaScript/TypeScript code block to run. The recipe used a fresh, unprivileged lab-node:22 container with 2 CPUs, 4 GB RAM, no published ports and no secrets. Its target was a package quick start, separate from the October source-repository checks.

The recipe recorded a 6-second clone step. Its install record says npm install htmx.org@latest installed htmx.org 2.0.11 in 1.6 s. After installation, it recorded 988 KB in node_modules and 0 packages besides htmx.org. These measurements belong to that package recipe and its recorded environment.

The snippet step was marked FAILED, with the missing-code-block explanation. The README instead demonstrates a script tag and an HTML button that posts to /clicked. The recipe then completed teardown successfully. The failed step identifies where this automation stopped; the README's interaction requires a browser and an endpoint returning replacement HTML.

Our October harness measured the source repository at fa978b2 using command outcomes and elapsed durations. Installation succeeded in 13 seconds, and the test step succeeded in 81 seconds. The development tree contained 502 dependencies occupying 171 MB. The following table keeps those source-repository observations separate from the November package-install recipe, which recorded a different dependency footprint.

Source-repository check Recorded result
npm installation Succeeded in 13 seconds
Development dependencies 502 dependencies recorded, 171 MB on disk
Build Skipped because there was no build script or target
Tests Succeeded in 81 seconds
npm audit 0 known vulnerabilities: 0 critical, 0 high, 0 moderate, 0 low
Repository scan 639 files, about 57,804 source lines, 94.9 MB checked out
Project signals 1 CI workflow file, a tests directory, no Dockerfile detected

The October configuration was 3 CPUs, 8 GB RAM and image label lab-node:22. Its dependency measurement describes the repository development tree, while November's installed-size observation describes the package recipe. The README makes the same practical distinction: application use starts with a browser script, whereas contributor setup installs development dependencies and serves the browser test suite from the repository root.

Where people get stuck: headers, history and inherited attributes

Hunter reports that RFC Hub needed extra handling for refresh and redirect headers, while server errors could leave the screen unchanged. His difficulty was deciding how an endpoint should respond when different screens needed different updates. He describes helper functions that distinguish ordinary and htmx requests, but dislikes the resulting connection between an endpoint and its calling interface.

Report What went wrong Response in the discussion How to use it now
David-Guillot and josephetareh in #854 Repeated back navigation restored an address with the wrong content in historical Django integrations josephetareh reports setting historyCacheSize to zero; reports include 1.7.0 Retain the repeated navigation sequence as a regression case
scrhartley in #3243 Parent boost settings affected target, select and swap behavior in ordinary fragment requests Explicit overrides and a boost-attrs extension were discussed, including extension placement Review inherited attributes when combining page navigation and isolated widgets
carlos-verdes and runeksvendsen in #1911 hx-get waited for a complete chunked response Community extensions followed, with reported use in haskell-function-graph Choose the transport and extension deliberately

At Contexte, David-Guillot describes selecting a facet, adding another facet, going back successfully, selecting the second facet again and going back again. The repeated sequence exposed the failure. The original Django report likewise describes a first successful return followed by an address change without the expected content. Those reports make repeated navigation a more specific evaluation case than a single back-button click.

The htmx 4 migration guide says error responses swap by default. Responses with 4xx and 5xx status codes are included; 204 and 304 are excluded. A server returning HTML with a 422 or 500 therefore supplies target content under that default. The guide directs applications to design error responses as swap content or use hx-status for per-code behavior.

Streaming and long lists need their own design

Issue #1911 reports that hx-get waits for the full chunked response before displaying content. The discussion includes community extensions and reported successful use in haskell-function-graph. That interaction concerns displaying portions of one response before it finishes. It differs from receiving event messages or exchanging data over a WebSocket, even though all three can support interfaces that update over time.

The htmx 4 announcement names three streaming HTML extensions: hx-sse for text/event-stream, hx-ws for WebSockets and hx-multipart for multipart/mixed. These names identify different server-response mechanisms. Choosing one also selects the corresponding backend work: an event stream, a WebSocket connection or a multipart response. The announcement documents those transport choices rather than treating every streaming request as the same feature.

Long lists raise a separate question about retaining older page elements. Issue #130 requests bounded insertion that removes older elements, and a contributor describes experimental work. Its proposed behavior trims old items as new ones arrive. Appending every result and maintaining a bounded set of DOM elements are different list designs, with different consequences as a reader continues scrolling.

Security starts with the HTML you return

Console's htmx 2.0 review identifies escaping and Content Security Policy as security considerations because behavior lives in the DOM. The review specifically says to think through escaping and which attributes to allow. That concern belongs alongside the server's rendering rules: the HTML inserted into a page contains both visible content and attributes that describe browser behavior.

The htmx 4 announcement supplies a concrete inheritance example involving a CSRF token. Its upgrade-checker output flags hx-headers on a parent: without the new inheritance declaration, the header does not reach the child request element and the server rejects the request. The maintainers call explicit attribute inheritance the largest upgrade task, connecting a template change directly to request handling.

Version 4 is released, while the default package stays on 2

The recorded latest-release metadata identifies v4.0.2, dated November 18, 2026. The README's quick start separately references 2.0.11, and our November package recipe recorded that same package version. A release tag, a README example and npm's default distribution channel answer different version questions. Keep those identities attached to the source or run that records them.

The 4.0 announcement says 2.x will remain npm's latest and the 4.0 line will remain next until some point in early 2027. The November observation of htmx.org 2.0.11 is consistent with that policy. An explicit version in an installation command or script URL makes the intended branch clear; the README itself uses a versioned 2.0.11 script URL.

For existing applications, the migration guide documents explicit inheritance, renamed events, changed error-response swaps, re-fetching on back navigation and a reversed order for out-of-band swaps. Those changes affect templates, responses and event handlers. The migration guide lists the behavior changes, while our existing htmx 4 upgrade article addresses the transition separately from this adoption review.

The repository metadata records a last push of November 20, 2026. That timestamp and the November 18 release date are dated activity signals. The specific behavior changes discussed here come from the 4.0 announcement and migration guide, which describe inheritance, events, history and response handling. The measured repository revision remains fa978b2, and the November quick-start revision remains 51c3e67bcedc.

htmx vs React, Alpine.js, Turbo and Unpoly

Choose htmx for server-rendered updates, evaluate a client framework when shared browser state dominates, and compare Turbo or Unpoly when their navigation conventions fit. Hunter's applications illustrate the rendering-and-state decision: RFC Hub uses server-rendered EJS views and application JavaScript, while Map Buddy uses Vue for interactive maps and a mobile-style interface. His account ties each choice to a particular workload.

Choice Reason to consider it Decision for your application
htmx vs React Hunter anticipates reconsidering his framework if complex screen state grows Start with where views are rendered and state is coordinated
htmx with Alpine.js The older extension catalog describes preserving Alpine state when components are swapped Account for local component state when replacing HTML
htmx vs Turbo Turbo documents Drive for links and forms, Frames for scoped navigation, and Streams for HTML changes Compare its navigation and frame conventions with your application
htmx vs Unpoly Unpoly documents targeted updates from responses that can contain a full HTML page Compare it when full-page URLs should also support fragment updates

Turbo Frames scope navigation to independent page contexts. Its README also describes Drive for links and forms, and Streams for page changes delivered over WebSocket or in response to form submissions. These documented mechanisms offer concrete comparison points for an application already returning HTML. The decision concerns which navigation conventions fit your routes and templates, rather than a framework ranking.

Unpoly accepts full-page HTML responses and updates the targeted fragment. Its README says content outside that fragment keeps scroll positions and unsaved form input, and each URL works on its own. Alpine addresses a different part of the interface: local behavior can accompany server requests, while replacing a component raises the state-preservation question described by the older htmx extension catalog.

What the other reviews get wrong

Strapi's package command and LogRocket's Internet Explorer claim conflict with the documented package name and version boundaries. The digipodium examples also mix response selection with destination selection, and JSON responses with HTML swaps. The corrections below name the tutorial and the relevant documentation or discussion, so each correction concerns a specific command, attribute or version claim.

The older documentation's statement that 2.x is latest also needs its distribution context. The recorded release metadata identifies v4.0.2, while the 4.0 announcement explains why npm's latest tag stays on 2.x. These facts can coexist. A tutorial using a 2.x script is describing that branch, even when a newer major release exists through a different distribution tag.

Isaac Harris-Holt's walkthrough ties graceful degradation to boosted native anchors and forms. A native anchor has a destination; a native form has an action and method. Hunter's fallback request shows why an hx-post attribute alone should not be treated as a complete native form submission path. The underlying HTML determines what the browser can do without the enhancement.

Questions people ask

htmx is a JavaScript library, not another version of HTML. Its attributes describe requests, triggers and updates to target elements, and its documentation says servers typically return HTML rather than JSON. The questions below cover that identity, the split between release and package versions, tutorial starting points, and the practical choice between server-rendered updates and browser-local behavior.

What does htmx mean, and does it have a full form?

The README presents htmx as "high power tools for HTML." It explains its purpose through questions about which elements can make requests, which events trigger them and which part of the screen receives an update. That project description explains the name's context without inventing an acronym expansion. The documented model extends ordinary HTML interactions through attributes interpreted by the library.

Is htmx another version of HTML?

No. htmx is browser JavaScript that interprets attributes added to HTML. An ordinary anchor requests a page, while an htmx element can request content for a chosen region. The official documentation describes request triggers, HTTP verbs and targets, including a button that posts to /clicked and replaces the element identified by hx-target with the response content.

What is the latest htmx version, and should I use htmx 4?

The recorded release metadata identifies v4.0.2, dated November 18, 2026; the November package recipe installed 2.0.11 through npm's latest channel. The 4.0 announcement explains that distribution policy. Choose the intended major version explicitly. For an existing application, the migration guide identifies template, event, history and error-response changes that affect the upgrade work.

Where should I start with an htmx tutorial and the documentation?

Start with the README's button and an HTML-returning /clicked endpoint. The documented interaction posts a request and replaces the button with the response. For Go, alexedwards describes a tutorial covering templates, partial and full responses, redirects, errors and configuration. Those topics connect the attributes to the backend responses needed for an application interaction.

Should I choose htmx or React for my application?

Choose htmx when server-rendered views fit the interactions; evaluate a client framework when complicated browser state drives the interface. Hunter identifies growing screen-state complexity as a reason he might change frameworks. His RFC Hub account combines EJS views, request attributes and about 200 lines of application-specific browser JavaScript, describing a concrete division of responsibilities.

How does htmx performance compare with React?

Ark Protocol's article puts three hours versus three days in its title and describes implementing the same resend-OTP feature twice. That is a personal implementation account. Our 13-second installation and 81-second test duration instead measure repository command completion. Development time and command duration answer different questions, and neither is an application response-time result.

How does htmx compare with Vue?

Hunter reports using Vue for Map Buddy's interactive maps and mobile-style interface, while choosing htmx for RFC Hub's proposal-management screens. His account describes different applications with different requirements. It offers a workload-based starting point: decide which interactions require browser-local coordination and which can be expressed through server-rendered HTML responses, then assess those interactions in the intended architecture.

Can htmx replace a full SPA, or is it mainly suitable for simple projects?

RFC Hub and Contexte describe proposal workflows and faceted search, rather than static pages alone. A separate developer asks how to retain stale-while-revalidate navigation and local invoice calculations in issue #1443. Those requirements separate the decision into concrete interactions: replacing server-rendered content, navigating between cached views and calculating locally involve different responsibilities.

Is htmx worth learning as a beginner building freelance landing pages?

The README offers a specific learning exercise: send a request from a button and replace it with server-returned HTML. The beginner discussion asks whether htmx suits freelance landing-page work, while the documentation explains the request-and-response model. Begin with an interaction that needs a server response, so the exercise includes both page markup and its endpoint.

Does htmx still offer advantages when AI generates the code?

Commenters in r/htmx identify locality of behavior as a reason they prefer it with coding agents. One commenter argues that nearby behavior reduces exploration before changes. Generated code still needs the installed version's contracts: the migration guide documents renamed events and the replacement of htmx.logAll() with htmx.config.logAll = true in version 4.

Can htmx deliver rich, sophisticated interactive interfaces?

Contexte's faceted search and RFC Hub's editor and upload workflow describe independently updating parts of an interface. Hunter also uses ordinary browser JavaScript, including comment rendering. htmx itself is JavaScript; its attributes express request-and-swap behavior. The application can therefore combine server-rendered updates with local interaction code rather than requiring every interaction to take the same path.

What we have not tested yet

Our recorded runs cover repository checks and a package recipe that stopped before a browser interaction. We have not tested an application under load, a 2-to-4 migration, current reproductions of historical issues or streaming-extension combinations. Competing frameworks were not run on the same workload. Application latency, throughput, accessibility, drag-and-drop, offline recovery and a general productivity ratio have no measured results here.

The October summary contains no raw toolchain versions, test count or complete test logs. The lab-node:22 label identifies the configured image rather than an actual runtime or operating-system version. Its zero-advisory result is a dependency-scan observation rather than a security audit. Console's warning is not accompanied by a worked CSP deployment or escaping test. The November recipe contains no application Q&A or screenshot records, and its failed snippet step does not demonstrate a broken HTML button.

Historical issue discussions contain user reports, workarounds and experimental implementations. They do not demonstrate that #130's bounded-list proposal or #2308's forked out-of-band modifier work shipped in a particular release. The historical history and inheritance reports do not demonstrate those defects in v4.0.2. The release metadata supports its tag and date, but no readable v4.0.2 release notes establish individual fixes. Repository activity also does not measure support response times.

The Reddit and X discussions do not measure AI-assisted maintenance, long-term reliability or a Go performance advantage. Hunter's Vue account does not supply a worked comparison with Next.js, Angular or Svelte. Rendered layout, resolved links, related links, recommendation modules and template content also fall outside the recorded runs. A next application evaluation should exercise a form error, repeated back navigation and a local widget whose state must survive server updates.

How does htmx differ from React Server Components?

The evidence here cannot establish the difference between htmx and React Server Components: it documents only the htmx side. The htmx documentation describes HTML responses updating a target element, while the X post merely raises the comparison. A substantive answer needs corresponding React Server Components implementation evidence; the question alone supplies no response contract or behavior to compare.

Alternatives

ProjectWhat it isPick it when
React gh↗A client-framework candidate when browser state drives the architecture.Evaluate a client framework when substantial state must remain coordinated in the browser. Hunter's account identifies growing screen-state complexity as his reason to reconsider htmx.
TurboHTML navigation through Drive, Frames and Streams.Compare Turbo when scoped navigation and its documented frame and stream conventions match the application.
UnpolyTargeted fragment updates from full-page HTML responses.Compare Unpoly when full-page URLs and targeted updates should share the same server responses.

Sources

  1. htmx repository
  2. htmx documentation
  3. htmx 4 release announcement
  4. htmx 4 migration guide
  5. htmx v4.0.2 release
  6. Turbo repository
  7. Unpoly repository

More web reviews