alovajs/alova

The request strategy layer for JavaScript. 20+ ready-made strategies cut your request code by up to 70%

TypeScript

4,022

1,233 commits

updated Oct 10, 2026

See the code

README

Stop building request logic. Start shipping features.
The request strategy layer for JavaScript — cut your request code by up to 70%.

English | 中文 | 日本語

Documentation | Demos

npm build coverage status stars discord wechat tree shaking typescript strategies license

Sponsors

Thanks to these generous sponsors for supporting alova's development.

watchthis.dev      worma      Sealed Rose — AI Deepfake Detector

What is alova?

alova (pronounced /əˈləʊva/) is the request strategy layer for JavaScript. You've hand-written pagination, forms, uploads and retries countless times — now just pick one of 20+ ready-made request strategies and cut your request code by up to 70%.

You don't have to throw away the axios or fetch you already know. alova sits right on top of your existing request library and takes over the logic you keep rewriting. One API set spans React, Vue, Svelte, Solid, mini-programs and the server — learn once, use everywhere, so you can focus on business logic on both the client and the server.

Here is a paginated list with prefetch, auto-cache and auto-sync on create/update/delete — about five lines of code:

const todoList = (page, size) => alova.Get('/api/todos', { params: { page, size } });

const { loading, data, page, pageSize, pageCount, total } = usePagination(todoList);
// auto pagination · prefetch next page · auto cache sync on create/update/delete

Features

Instead of listing what alova "is", here's what it solves for you:

The boilerplate you're tired ofWhat alova gives youThe payoff
Hand-writing pagination, forms, uploads, SSE statesusePagination / useForm / useUploader / useSSEUp to 70% less boilerplate
Server-side rate limiting & retries (incl. distributed)alova/serverCapabilities React Query / SWR simply don't cover
Rebuilding the same logic for every frameworkOne API setSpans React / Vue / Svelte / Solid / mini-programs
Manually maintaining cache invalidationMulti-level cache (L1/L2) + declarative invalidation via hitSourceCache invalidation is no longer painful
Copy-pasting API info between docs and your editorwormaAPI hints & docs show up right inside your editor

And of course:

  • Easy to use, watch the video to get started in 5 mins.
  • Full compatibility with your favorite HTTP clients and UI frameworks.
  • 20+ high-performance request strategies (business modules) for building faster apps.
  • Request sharing and response cache to improve app performance.
  • End-to-end type safety.
  • Advanced OpenAPI solution worma: from one OpenAPI spec, generate type-safe calling code, TypeScript types, full API docs, and API knowledge for your AI coding assistant.

When should you use alova?

alova is honest about where it shines — and where a simpler tool is enough:

Your situationRecommendation
Simple CRUD + cachingReact Query / SWR are enough
Complex admin / forms / pagination / uploads✅ alova is clearly a step ahead
Cross-platform (Web + mini-program / uni-app / Taro)✅ One API set covers everything
Server-side request governance (rate limit / retry / distributed)✅ alova is almost the only choice
OpenAPI → type-safe code + AI-friendly API knowledge✅ Pair with worma (works out of the box with alova)

Not sure alova is right for you? Read When should you NOT use alova? for the honest reverse list before you commit.

Is there any difference?

Unlike libraries such as @tanstack/react-query, swrjs, and ahooks's useRequest, alova aims to make API integration very easy and efficient, while maintaining more efficient data interaction and bringing a smoother experience to users.

For the same paginated list, React Query needs roughly 25 lines while alova's usePagination takes about 5 — see the no-BS comparison.

You can also check Comparison with other request libraries to learn more about the differences of alova.

Join the community

We need your support

If you like alova, we are very grateful for giving us a star in the upper right corner, which is a recognition and encouragement for our work.

Welcome to contribute

We are honored to receive active participation from developers around the world in Issues and Discussions.

We hope to make alova a common project for everyone who is willing to participate. We encourage everyone to become a contributor to the alova community with an open and inclusive attitude. Even if you are a junior developer, as long as your ideas meet the development guidelines of alova, please participate generously.

Effective contributions will win you a certain reputation in the Alova community. Before contributing, please be sure to read the Contribution Guide in detail to ensure your contribution is effective.

Changelog

Link

Contributors

LICENSE

MIT

ajax
alova
axios
bff
fetch-api
hooks
nextjs
nuxtjs
reactjs
request
solid
ssr
superagent
svelte
taro
typescript
uniapp
vuejs
xmlhttprequest

alovajs/alova

The request strategy layer for JavaScript. 20+ ready-made strategies cut your request code by up to 70%

TypeScript

4,022

1,233 commits

updated Oct 10, 2026

See the code

README

Stop building request logic. Start shipping features.
The request strategy layer for JavaScript — cut your request code by up to 70%.

English | 中文 | 日本語

Documentation | Demos

npm build coverage status stars discord wechat tree shaking typescript strategies license

Sponsors

Thanks to these generous sponsors for supporting alova's development.

watchthis.dev      worma      Sealed Rose — AI Deepfake Detector

What is alova?

alova (pronounced /əˈləʊva/) is the request strategy layer for JavaScript. You've hand-written pagination, forms, uploads and retries countless times — now just pick one of 20+ ready-made request strategies and cut your request code by up to 70%.

You don't have to throw away the axios or fetch you already know. alova sits right on top of your existing request library and takes over the logic you keep rewriting. One API set spans React, Vue, Svelte, Solid, mini-programs and the server — learn once, use everywhere, so you can focus on business logic on both the client and the server.

Here is a paginated list with prefetch, auto-cache and auto-sync on create/update/delete — about five lines of code:

const todoList = (page, size) => alova.Get('/api/todos', { params: { page, size } });

const { loading, data, page, pageSize, pageCount, total } = usePagination(todoList);
// auto pagination · prefetch next page · auto cache sync on create/update/delete

Features

Instead of listing what alova "is", here's what it solves for you:

The boilerplate you're tired ofWhat alova gives youThe payoff
Hand-writing pagination, forms, uploads, SSE statesusePagination / useForm / useUploader / useSSEUp to 70% less boilerplate
Server-side rate limiting & retries (incl. distributed)alova/serverCapabilities React Query / SWR simply don't cover
Rebuilding the same logic for every frameworkOne API setSpans React / Vue / Svelte / Solid / mini-programs
Manually maintaining cache invalidationMulti-level cache (L1/L2) + declarative invalidation via hitSourceCache invalidation is no longer painful
Copy-pasting API info between docs and your editorwormaAPI hints & docs show up right inside your editor

And of course:

  • Easy to use, watch the video to get started in 5 mins.
  • Full compatibility with your favorite HTTP clients and UI frameworks.
  • 20+ high-performance request strategies (business modules) for building faster apps.
  • Request sharing and response cache to improve app performance.
  • End-to-end type safety.
  • Advanced OpenAPI solution worma: from one OpenAPI spec, generate type-safe calling code, TypeScript types, full API docs, and API knowledge for your AI coding assistant.

When should you use alova?

alova is honest about where it shines — and where a simpler tool is enough:

Your situationRecommendation
Simple CRUD + cachingReact Query / SWR are enough
Complex admin / forms / pagination / uploads✅ alova is clearly a step ahead
Cross-platform (Web + mini-program / uni-app / Taro)✅ One API set covers everything
Server-side request governance (rate limit / retry / distributed)✅ alova is almost the only choice
OpenAPI → type-safe code + AI-friendly API knowledge✅ Pair with worma (works out of the box with alova)

Not sure alova is right for you? Read When should you NOT use alova? for the honest reverse list before you commit.

Is there any difference?

Unlike libraries such as @tanstack/react-query, swrjs, and ahooks's useRequest, alova aims to make API integration very easy and efficient, while maintaining more efficient data interaction and bringing a smoother experience to users.

For the same paginated list, React Query needs roughly 25 lines while alova's usePagination takes about 5 — see the no-BS comparison.

You can also check Comparison with other request libraries to learn more about the differences of alova.

Join the community

We need your support

If you like alova, we are very grateful for giving us a star in the upper right corner, which is a recognition and encouragement for our work.

Welcome to contribute

We are honored to receive active participation from developers around the world in Issues and Discussions.

We hope to make alova a common project for everyone who is willing to participate. We encourage everyone to become a contributor to the alova community with an open and inclusive attitude. Even if you are a junior developer, as long as your ideas meet the development guidelines of alova, please participate generously.

Effective contributions will win you a certain reputation in the Alova community. Before contributing, please be sure to read the Contribution Guide in detail to ensure your contribution is effective.

Changelog

Link

Contributors

LICENSE

MIT

ajax
alova
axios
bff
fetch-api
hooks
nextjs
nuxtjs
reactjs
request
solid
ssr
superagent
svelte
taro
typescript
uniapp
vuejs
xmlhttprequest

Project health

Latest release

3.5.5 · Aug 21, 2026

Releases this year

8

Significant stargazers

Kevin Deng

4,834 followers · starred Jul 2023

Loyalsoldier

2,541 followers · starred May 2025

zhangenming

13 followers · starred May 2025

诺墨

121 followers · starred Nov 2025