Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add piyiotisk/htmx-skills --skill htmxgit clone --depth 1 https://github.com/piyiotisk/htmx-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/piyiotisk/htmx-skills/htmx)<a href="https://agentmods.dev/skills/piyiotisk/htmx-skills/htmx"><img src="https://agentmods.dev/badge/skills/piyiotisk/htmx-skills/htmx.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00083 | $0.03182 |
| Opus 5 | $0.00042 | $0.01591 |
| Sonnet 5 | $0.00017 | $0.00636 |
| Haiku 4.5 | $0.00008 | $0.00318 |
Grade A, and why
htmx scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 188 lines — stays where its author put it; the contents beside it link to each section on GitHub.
htmx
htmx lets any element issue an AJAX request on any event using any HTTP verb, and swap the returned HTML into any target. The server returns HTML fragments, not JSON. Keep logic in HTML attributes (Locality of Behavior) and keep state on the server (HATEOAS).
Core Mental Model
- An element is triggered by an event (
hx-trigger). - It issues an HTTP request via
hx-get/hx-post/hx-put/hx-patch/hx-delete. - The server responds with an HTML fragment.
- htmx swaps that HTML into a target (
hx-target) using a swap strategy (hx-swap).
<button hx-post="/clicked" hx-trigger="click" hx-target="#out" hx-swap="outerHTML">
Click Me!
</button>
<div id="out"></div>
You can use the data-hx-* prefix if you need valid-by-DTD HTML (e.g. data-hx-post).
Example usage
Invoke explicitly when starting htmx work (Claude Code: /htmx:htmx).
| Task | Example prompt |
|---|---|
| Live search | "Add debounced hx-get search swapping into #results." |
| Inline edit | "Click Edit replaces this card with a form; Cancel restores it." |
| Delete + counter | "Delete row with hx-delete and OOB-update #contact-count." |
| Validation UX | "422 errors in #form-errors, success replaces the form." |
| Boosted nav | "Boost #main links but keep sidebar PDFs as full page loads." |
| Code review | "Review this template for htmx inheritance and XSS issues." |
For full HTML + server response examples, see examples.md. For pattern recipes, see references/examples/.
Installing
CDN (fastest start; pin the version, consider self-hosting in production):
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/htmx.min.js"
integrity="sha384-H5SrcfygHmAuTDZphMHqBJLc3FhssKjG7w/CeCpFReSfwBWDTKpkzPP8c+cLsK+V"
crossorigin="anonymous"></script>
npm: npm install [email protected]. With bundlers, also expose it globally if needed: window.htmx = require('htmx.org').
What ships with it
60 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- evals/evals-iter2.json 3.8 KB
- evals/evals-iter3.json 11 KB
- evals/evals.json 4.1 KB
- examples.md 5.0 KB
- references/api.md 20 KB
- references/attributes/hx-boost.md 2.5 KB
- references/attributes/hx-confirm.md 1.4 KB
- references/attributes/hx-delete.md 1.3 KB
- references/attributes/hx-disable.md 534 B
- references/attributes/hx-disabled-elt.md 2.9 KB
- references/attributes/hx-disinherit.md 2.2 KB
- references/attributes/hx-encoding.md 682 B
- references/attributes/hx-ext.md 1.2 KB
- references/attributes/hx-get.md 1.4 KB
- references/attributes/hx-headers.md 1.8 KB
- references/attributes/hx-history-elt.md 897 B
- references/attributes/hx-history.md 1.0 KB
- references/attributes/hx-include.md 3.0 KB
- references/attributes/hx-indicator.md 4.2 KB
- references/attributes/hx-inherit.md 1.6 KB
- references/attributes/hx-on.md 3.9 KB
- references/attributes/hx-params.md 865 B
- references/attributes/hx-patch.md 1.0 KB
- references/attributes/hx-post.md 1.0 KB
- references/attributes/hx-preserve.md 1.9 KB
- references/attributes/hx-prompt.md 616 B
- references/attributes/hx-push-url.md 1.7 KB
- references/attributes/hx-put.md 1.0 KB
- references/attributes/hx-replace-url.md 1.6 KB
- references/attributes/hx-request.md 879 B
- references/attributes/hx-select-oob.md 1.7 KB
- references/attributes/hx-select.md 770 B
- references/attributes/hx-swap-oob.md 4.5 KB
- references/attributes/hx-swap.md 5.8 KB
- references/attributes/hx-sync.md 3.8 KB
- references/attributes/hx-target.md 2.0 KB
- references/attributes/hx-trigger.md 8.7 KB
- references/attributes/hx-validate.md 585 B
- references/attributes/hx-vals.md 2.2 KB
- references/attributes/hx-vars.md 1.6 KB
- references/cheatsheet.md 13 KB
- references/docs.md 92 KB
- references/events.md 23 KB
- references/examples/active-search.md 16 KB
- references/examples/animations.md 9.6 KB
- references/examples/async-auth.md 1.5 KB
- references/examples/bulk-update.md 5.1 KB
- references/examples/click-to-edit.md 3.2 KB
- references/examples/click-to-load.md 2.7 KB
- references/examples/confirm.md 2.8 KB
- references/examples/delete-row.md 3.3 KB
- references/examples/dialogs.md 1.6 KB
- references/examples/edit-row.md 7.3 KB
- references/examples/file-upload-input.md 2.2 KB
- references/examples/file-upload.md 1.7 KB
- references/examples/infinite-scroll.md 2.9 KB
- references/examples/inline-validation.md 4.6 KB
- references/examples/keyboard-shortcuts.md 1.4 KB
- references/examples/lazy-load.md 1.3 KB
- references/examples/modal-bootstrap.md 3.0 KB
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 8d ago First seen · 188 lines · 83 tokens per session scan A 8d61a8761bd9
htmx is a skill published in the GitHub repository piyiotisk/htmx-skills (7 stars, last pushed 2mo ago), licensed MIT. It adds 83 tokens to every session and 3,182 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
copilotkit-upgrade
Use when migrating a CopilotKit v1 application to v2 -- updating package imports, replacing deprecated hooks and components, switching from GraphQL runtime to AG-UI protocol runtime, and resolving breaking API changes.
nextjs-pages-router
Set up tRPC in Next.js Pages Router with createNextApiHandler, createTRPCNext, withTRPC HOC, SSR via ssr option and ssrPrepass, SSG via createServerSideHelpers with getStaticProps, and server-side helpers for getServerSideProps prefetching.
with-tanstack-query
Compose Angular Query with signal-owned Table filtering, sorting, and pagination state using reactive query options, manual row-model boundaries, direct query data, server counts, and valid injection context.
auth-web-cloudbase
CloudBase Web Authentication Quick Guide for frontend integration after auth-tool has already been checked. Provides concise and practical Web authentication solutions with multiple login methods and complete user management.
service-digital-engagement-channel-configure
Configures and deploys enhanced chat Messaging Channels for Messaging for In-App and Web (MIAW). Use when the user needs to create, deploy, and activate a messaging channel configured with Omni-Channel Flow, Omni-Channel Queue, User, or Agentforce Service Agent routing. Generates MessagingChannel metadata, deploys it…
om-system-extension
Extend installed Open Mercato modules through UMES enrichers, interceptors, mutation guards, widgets, menus, entity extensions, events, component/page replacements, and overrides. Use for "extend core", "add field/column/action", "hide page", "intercept API", "UMES", or "rozszerz moduł".