# AOS (Animate On Scroll) — card for AI agents

Small JS library that fades, slides and zooms elements in as you scroll, set with data-aos attributes in HTML.

Category: Web animation examples and effects (also: UI animation (Lottie, Rive)) · maker Michał Sajnóg · checked 2026-11-05 · style: minimal

## Price
- Price: Free
- Free tier: Fully free.

## License
MIT — https://raw.githubusercontent.com/michalsnik/aos/next/LICENSE

- commercial: **yes** (Commercial use OK)
  > to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  (https://raw.githubusercontent.com/michalsnik/aos/next/LICENSE)
- attribution: **no** (No credit needed)
  > The above copyright notice and this permission notice shall be included in all
  (https://raw.githubusercontent.com/michalsnik/aos/next/LICENSE)
- in app: **yes** (Can ship inside your app)
  > to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  (https://raw.githubusercontent.com/michalsnik/aos/next/LICENSE)
- redistribute: **yes** (Can pass the files on to your own users)
  > to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  (https://raw.githubusercontent.com/michalsnik/aos/next/LICENSE)

## Rules to follow
- Keep the MIT notice if you redistribute the code.

## Can an AI agent use it by itself?
**Yes** · package: Agent installs a package or loads it from a CDN

## How an agent gets files
- npm install aos (or CDN), call AOS.init(), add data-aos="fade-up" to elements. (sign-in: none)
- Formats: js, css, html

## How to connect
- Package (npm/PyPI)
- npm: `npm install aos`
- Repository: https://github.com/michalsnik/aos
- Website: https://michalsnik.github.io/aos/

## Notes
npm latest is 2.3.4. For new projects CSS scroll-driven animations can replace it natively.

## Numbers (AgentGid data)
- Gid Score: 47
- GitHub stars: 28,057
- Downloads last week: 324,927
- Used in 6 public projects set up for AI coding agents

## Lines to paste into your prompt or AGENTS.md

```
- AOS (Animate On Scroll) (Web animation examples and effects, UI animation (Lottie, Rive)). Small JS library that fades, slides and zooms elements in as you scroll, set with data-aos attributes in HTML. Price: free; commercial use OK; no credit needed. Style: minimal.
  Connect: npm aos.
  Get files: npm install aos (or CDN), call AOS.init(), add data-aos="fade-up" to elements (js, css, html).
  Rule: Keep the MIT notice if you redistribute the code.
  License: https://raw.githubusercontent.com/michalsnik/aos/next/LICENSE (checked 2026-11-05; details: https://agentgid.com/assets/aos/)
```

## Links
- AgentGid page: https://agentgid.com/assets/aos/
- Is it free for commercial use? https://agentgid.com/assets/aos/commercial-use/
- Source: https://michalsnik.github.io/aos/
- Source: https://raw.githubusercontent.com/michalsnik/aos/next/LICENSE
- Source: https://registry.npmjs.org/aos/latest


## AOS: page blocks that fade in as you scroll

AOS (Animate On Scroll) is a small free script that makes parts of a page fade, slide, zoom or flip into place when the visitor scrolls to them. You or your AI assistant add one attribute to an element, such as data-aos="fade-up", and call one start function. Its last release is from 2018, so it suits simple sites more than new app projects.

### Where to use it
- Landing page sections that appear on scroll: Make feature blocks, screenshots and quotes on a landing page fade or slide in as the visitor reaches them.
- Cards that come in one after another: Let pricing cards, team photos or feature tiles appear in a short sequence instead of all at once.
- Animate once, not on every pass: On long pages, show each block's entrance only the first time, so scrolling back up does not replay every effect.
- Calmer pages on phones: Switch the effects off on phones or tablets, or under your own rule such as narrow screens.
- Trigger from another block: Start an element's animation when a different block reaches the screen, for example a fixed button that appears with a section.
- Portfolio and case-study pages: Reveal project images and short captions one by one as a visitor reads down a portfolio or case-study page. (idea, not from the official pages)

### How to start
- Install the stable version (or download it) and load its style file and script.

```
npm install aos --save
```

- Start AOS once on the page.

```
AOS.init();
```

- Add data-aos with an effect name to each element, and data-aos-* attributes to tune it.

```
<div data-aos="fade-up" data-aos-anchor-placement="top-center">
```


### License
MIT license: free for personal and paid sites, and you may change and share the code. Keep the copyright and license notice with copies of the code you ship.

### Good to know
- The stable version is 2.3.4 from October 2018. Version 3 is still a beta (3.0.0-beta.6).
- The project's main page on GitHub describes the unfinished version 3. Version 2 instructions are on a separate page.
- In version 2, blocks animate back out when you scroll up past them, unless you set the once option.
- Animation length and delay only work from 50 to 3000 milliseconds, in steps of 50. Other values need a few lines of your own CSS.
- It runs in the visitor's browser; no account, key or outside service is involved.

Checked 2026-11-09 against: https://michalsnik.github.io/aos/, https://github.com/michalsnik/aos, https://github.com/michalsnik/aos/blob/master/README.md, https://github.com/michalsnik/aos/blob/next/README.md, https://github.com/michalsnik/aos/blob/next/LICENSE, https://registry.npmjs.org/aos/latest, https://registry.npmjs.org/aos, https://api.github.com/repos/michalsnik/aos

### Mistakes to avoid
- Don't: Following the GitHub front page (aos@next) for a project that ran npm install aos → Do: Use the version 2 README (master branch) for aos 2.3.4, or install aos@next on purpose and pin 3.0.0-beta.6 (npm install aos gives 2.3.4, while the front-page README documents the 3.0 beta (for example the mirror option and aos:in events).)
- Don't: Leaving the animations on for people who asked their system for less motion → Do: Pass disable: window.matchMedia('(prefers-reduced-motion: reduce)').matches to AOS.init (Version 2.3.4 has no reduced-motion check of its own (none in its CSS or script in our demo); disable accepts any condition.)
- Don't: data-aos-duration="4000" or data-aos-delay="125" → Do: Use 50 to 3000 in steps of 50, or add your own CSS rule for other values (The timing values exist only as prepared CSS rules.)
- Don't: <div aos="fade-up"> (attribute from old tutorials) → Do: <div data-aos="fade-up"> (The plain aos attribute stopped working in version 2.0.0.)
- Don't: Loading aos.css and adding data-aos without calling AOS.init() → Do: Always call AOS.init() after the script loads (The CSS hides elements before their entrance (fade effects start at opacity 0), so without the script they stay invisible; seen in our demo files.)

### Questions
- Do I need to write JavaScript? Only one line, AOS.init(), plus the data-aos attributes in your HTML.
- Which effects are there? Fade, flip, slide and zoom effects in several directions, with a choice of easing curves.
- Can I turn it off on phones? Yes. Set disable to 'mobile', 'phone' or 'tablet', or to your own condition or function.
- What if content is added to the page later? AOS watches the page for changes and re-reads new elements; call AOS.refresh() if positions change in other ways.
- Can I use it in a commercial site? Yes. It is MIT licensed.

---
AgentGid's catalog is curated: every entry was checked against the maker's official pages (registry, repository, license and pricing pages) on the date shown; a license value shows the quote it stands on wherever AgentGid has one. Usage numbers come from AgentGid's own scan of public repositories set up for AI coding agents. Claims by makers are reported, not tested by AgentGid.
