🆚 Htmx vs. Preact

Type

JavaScript library
JavaScript library

About

Htmx is an open-source JavaScript library that extends HTML by adding custom attributes to trigger AJAX requests, CSS transitions, WebSockets, and Server-Sent Events directly in HTML markup.

It enables any HTML element to issue HTTP requests using any HTTP method and any event, injects server-returned HTML into targeted DOM elements without full page reloads, and supports lazy loading, infinite scroll, and inline editing.

Preact is a fast 3kB alternative to React with the same modern API.

It offers a virtual DOM, support for hooks and components, hydration for server-rendered content, and compatibility with many React-style tools through adapters.

Headquarters

Bozeman, Montana, United States
Hamilton, Ontario, Canada

Website

Pricing

Free ✔️ Open source
Free ✔️ Open source

Categories

JavaScript Libraries › Rank #163
JavaScript Libraries › Rank #201

Popularity

Determined by the number of sites using each technology.

The Htmx JavaScript library is 2.2 times more popular than Preact.
Total websites

Market share

JavaScript Libraries

Popularity by country

Determined by the number of sites detected from each country.

Htmx is more popular in the United States, Germany, and the United Kingdom, while Preact is more popular in Australia, Brazil, and Israel.
United States
Germany
United Kingdom
Netherlands
Australia
Brazil
Switzerland
France
Canada
Russia

Awards

Popularity by domain category

Determined by the number of sites in each category.

Htmx is more popular among sites focused on business, marketing and merchandising, and education and reference, while Preact is more commonly used on online shopping and fashion and beauty sites.
Online Shopping
Business
Marketing/Merchandising
Education/Reference
Fashion/Beauty
Travel
Sports
Blogs/Wiki
Internet Services
General News

Top sites

Top-ranked sites that use these technologies.

Name
Rank
#635
#1,535
View more ➝
Name
Rank
covers.com
#3,006
View more ➝

See also

🗃️ About This Data