PetarLib
by PetarMc1
PetarLib is a Fabric library that provides shared utilities for chat, logging, networking, task scheduling and notifications, for mods built on top of it.
What it does
PetarLib groups several helper modules in one dependency. The Chat module matches chat messages against patterns, the Log module provides a simple logging system for debugging, and the Net module handles network requests such as calls to external APIs. Task scheduling tools for asynchronous work sit in the Task module, and the Notification module lets other mods show messages in the action bar.
The library exists to keep common code in one place, so mods built with it do not need to rewrite the same utilities. It is used by mods from PetarMc1 and requires Fabric API. Files target 1.21.8, 1.21.9, 1.21.10, 1.21.11 and 26.1.2, and snapshot builds are published as well. Only the client needs it, and the license is MIT, so the code is open source with public links for the source, issue tracker and wiki.
Key features
Chat pattern matching
The Chat module matches incoming chat messages against patterns, so other mods can react to specific text.
Simple logging system
The Log module records messages in a basic logging system intended to help with debugging.
Network requests
The Net module sends and handles network requests, including calls to external APIs, from one shared place.
Task scheduling
The Task module provides scheduling and management tools for running and organizing asynchronous operations.
Action bar notifications
The Notification module lets mods display messages in the action bar above the hotbar.
Compatibility
Latest build for each game version and loader.
This mod also publishes snapshot builds. Snapshots are not shown in the matrix.
Requirements
Dependencies declared by the latest file for each loader.
Required 1
Required by 1 mod
Use cases
Who it’s for: Mod developers who want shared chat, logging, networking, task and notification code instead of writing their own, and players who run mods that depend on PetarLib.
How it compares
GrosseSauceLib is a Fabric library under the MIT License, client-side only and open source, with files for 1.21 – 1.21.5. Fabwork is open source under the MIT License, works on Fabric and Quilt for 1.19.2 – 26.3, and is optional on either side. Duchessentials is a client-side only Fabric mod under the MIT License, open source, with files for 1.21 – 26.2.
| Mod | Loaders | Game versions | Environment | Updated |
|---|---|---|---|---|
| PetarLib | Fabric | 1.21.8 – 26.1.2 | Client-side only | 2026-04-19 |
| GrosseSauceLib | Fabric | 1.21 – 1.21.5 | Client-side only | 2025-04-26 |
| Fabwork | Fabric and Quilt | 1.19.2 – 26.3 | Client or server, optional | 2026-09-18 |
| Duchessentials | Fabric | 1.21 – 26.2 | Client-side only | 2026-08-17 |
Questions
Does PetarLib need Fabric API?
Which game versions does PetarLib support?
Which mods use PetarLib?
In the catalog
PetarLib is one of 3,514 Library mods on ModsFinder, and one of 2,348 Library mods for Fabric. 15,189 mods support Minecraft 26.1.2.
More from PetarMc1
Similar mods
What the author says
By centralizing essential utilities in a dedicated library, mods built with PetarLib are cleaner and easier to update/work on. This means cleaner code and not having the need to rewrite the same code multiple times If you're a mod developer looking to integrate PetarLib into your project you can check the dev docs…
Official listing
- Modrinth page
- modrinth.com/mod/petarlib
- Owner
- PetarMc1
- Published
- 2025-12-22
- Updated on Modrinth
- 2026-04-19
- Facts verified
- 2026-10-15
