The next evolution of the most powerful Node.js library for building Discord bots
discord.js v15 represents a significant upgrade aimed at modernizing the developer experience and aligning with the latest Discord API advancements. This version introduces improved native support, better caching strategies, enhanced developer tooling, and future-ready design patterns.
npm install discord.js@dev
โ ๏ธ Requires Node.js v20.0.0 or laterUse nvm or nvm-windows for seamless version management.
- First-class integration with
fetch,AbortController,ReadableStream - Internal replacement of old polyfills
- Powered by
undici
- Native APIs for modals, context menus, and UI components
- Enhanced collectors & interaction responses
- Future command routing system in the works
- Fully customizable cache layers
- Toggle caching per resource (guilds, users, members, roles...)
- Expected REST-only mode for minimal memory use
- Fully retyped for advanced TypeScript support
- Smarter IntelliSense with
ClientandInteraction - Annotated JSDoc and better inline documentation
- Complete support for Discord Gateway v11
- Graceful reconnections & lifecycle tracking
| Feature | v14.x | v15 (dev) |
|---|---|---|
| Node.js Support | 16.x+ | 20.x+ |
Native fetch |
โ | โ |
| Modals Support | โ Full Native | |
| Typings & IntelliSense | Moderate | ๐ฅ Excellent |
| REST-only Mode | โ | โ (Expected) |
| Built-in Router | โ | ๐งช Planned |
- Node.js: v20.x or higher
- TypeScript: v5.x
- Linters: ESLint, Prettier
- Project Structure: Modular (commands, events, handlers)
| Area | Future Status | Description |
|---|---|---|
| ESM-only Support | Likely | CJS to be deprecated in favor of modern module systems |
| Built-in Command Router | In development | Simplified interaction-based routing system |
| CLI Tools | In discussion | Scaffolding and command generation support |
| Tree-shaking Support | Possible | Smaller production builds with dead-code elimination |
- ๐ Submit Issues
- ๐ง Join the Discord API Server
- ๐ฆ Follow @discordjs for updates
Built with โค๏ธ by the open-source community โ shaping the future of Discord bot development.