Mapepire is a modern, open‑source database access layer for IBM i that allows applications to connect to Db2 for i using secure WebSockets and JSON, instead of traditional ODBC or JDBC drivers.
It runs as a server (daemon) on the IBM i system and acts as a gateway between Db2 for i and modern application runtimes.
For IBM i developers working with RPG, CL, or SQLRPGLE programs, this exciting new tool is a game-changer. It streamlines the process of connecting modern applications to your Db2 for i database, making it faster and more efficient than ever before.
So what exactly is Mapepire?
Mapepire is a modern, open-source database client for Db2 for i. IBM released it in late August 2024 as a Technology Preview. It was built to solve the problems that many of us have had for years with traditional ODBC and JDBC drivers. This database access layer is built on top of secure WebSockets, designed to simplify the development of modern applications in .NET Core, Node.js, PHP, and similar platforms when working with Db2 for i.
Instead of running heavy client drivers on your application side, Mapepire uses a server component that sits on (or near) your IBM i. Your applications talk to this server using secure WebSockets over a single port. All the heavy lifting like CCSID handling, password management, and data conversion happens on the server. This keeps your client code light and simple.
The pronunciation debate: On the IBM-i Mapepire GitHub site it says Mapepire is pronounced ‘mapəpɪə’ or ‘MAH-pup-ee’ which seems nonsense to me! I've been pronouncing this as Mape (like Vape) Pire (like Fire) in my head while I am writing this. Let's see if I can reprogram the neural pathways to think "Mahpooopeeee"
Why Mapepire Exists
IBM and the open‑source IBM i community created Mapepire to address long‑standing problems with traditional Db2 for i connectivity:
- ODBC and JDBC clients are heavy and complex
- Client-side drivers must handle CCSIDs, encodings, and password levels
- Native drivers are hard to deploy in containers and cloud environments
- Communication protocols are not easy to extend to new languages
Mapepire moves this complexity to the IBM i server, allowing clients to remain lightweight.
How Mapepire Works (High Level)
- Runs as a daemon on IBM i
- Listens on a single secure port (default: 8076)
- Accepts WebSocket connections
- Receives JSON‑formatted SQL requests
- Executes SQL natively against Db2 for i
- Returns results as JSON
This architecture eliminates the need for client‑side ODBC/JDBC drivers.
What It’s Commonly Used For
Mapepire is designed for modern application architectures, including:
- Node.js, Python, Java (and others)
- Cloud‑native or containerized apps
- AI agents and tooling
- REST or MCP‑based services connecting to IBM i
- Lightweight services that need fast, short‑lived database queries
IBM explicitly uses Mapepire as the required database layer for the IBM i MCP Server, enabling AI and automation tools to talk to Db2 for i.
Key Characteristics
- Protocol: Secure WebSocket (ws / wss)
- Data format: JSON request/response
- Authentication: IBM i user profiles
- Port: 8076 (default)
- Installation: RPM (
yum install mapepire-server) - Service control: Service Commander (
sc start mapepire)
How Mapepire Compares to ODBC / JDBC
Important Clarification
Mapepire is not:
- A database replacement
- A query language
- A UI or reporting tool
It is strictly a connectivity layer that modernizes how applications talk to Db2 for i.
Mapepire is:
- Relatively new (introduced publicly in 2024)
- Actively promoted by IBM for AI and MCP tooling
- Becoming the preferred path for modern IBM i integrations
In the next few lessons, let's look at how MAPEPIRE is installed, configured and used with AI or MCP tools. Then, excitingly, we can look at how we RPG programmers, interact with it.


