P3X Redis UI Server

raw JSON →
2026.4.373 verified Sat Apr 25 auth: no javascript

Socket.IO backend server for the P3X Redis UI (v2026.4.373) with dual Angular/React frontends. Provides real-time Redis management via WebSocket events, supporting ioredis (standalone, cluster, sentinel), JWT-based authentication, AI query translation to Redis commands via Groq, and auto-decompression of 7 compressed formats (GZIP, ZIP, zlib, Zstandard, LZ4, Snappy, Brotli). Requires Node.js >=22. Released under MIT, no REST endpoints—all communication is socket-based. Differentiator: dual frontend stack (Angular + React) with full feature parity, 54 languages, 7 themes, and integrated login page.

error TypeError: Cannot destructure property 'startServer' of '...' as it is undefined.
cause CommonJS require() used for an ESM-only package.
fix
Use import { startServer } from 'p3x-redis-ui-server' or change your project to ESM.
error Error [ERR_REQUIRE_ESM]: require() of ES Module /path/to/p3x-redis-ui-server/index.js from /path/to/your/index.js not supported.
cause The package is ESM-only and cannot be required from CJS context.
fix
Convert your entry point to ESM by setting 'type': 'module' in package.json or use dynamic import().
error Error: listen EADDRINUSE :::7843
cause Port 7843 is already in use by another instance or process.
fix
Kill the existing process (lsof -ti :7843 | xargs kill) or change the port in config.
error Error: getaddrinfo ENOTFOUND redis-host
cause Hostname 'redis-host' could not be resolved. Check your connections configuration.
fix
Verify the hostname or IP in p3xrs.json for the Redis connection.
breaking Minimum Node.js version required: >=22. Versions <22 will throw an engine check error or fail to start.
fix Upgrade Node.js to v22 or later (currently tested on v24.14.1).
breaking ESM-only package since v2023.4. CommonJS require() throws MODULE_NOT_FOUND or ERR_REQUIRE_ESM.
fix Convert project to ESM (type: 'module' in package.json) or use dynamic import().
breaking No REST API endpoints. All Redis operations must be done via Socket.IO events. HTTP requests to paths other than /health and the frontend assets will fail.
fix Use Socket.IO client to communicate. See documentation for event list.
deprecated The 'p3xrs.connectionsFile' config option is deprecated in favor of 'p3xrs.connections.fileName' and will be removed in v2027.
fix Rename config key 'connectionsFile' to 'connections.fileName' in p3xrs.json.
gotcha Groq API key usage: The AI query feature sends your Groq API key to Groq's servers. Ensure the key has appropriate rate limits and permissions. The package does not encrypt the key in memory.
fix Store the API key in an environment variable (GROQ_API_KEY) and restrict network access to api.groq.com for the server process.
gotcha File descriptor leak: Running the server in a tight reconnect loop with many Redis connections may exhaust file descriptors. Limit number of concurrent connections or set ulimit.
fix Monitor open file handles with lsof. Reduce connection pool size in config or increase system limit (ulimit -n 65536).
npm install p3x-redis-ui-server
yarn add p3x-redis-ui-server
pnpm add p3x-redis-ui-server

Initializes the P3X Redis UI server with custom config, authentication, and AI query support.

import { startServer } from 'p3x-redis-ui-server';
import { createServer } from 'http';

const httpServer = createServer();
const apiServer = await startServer({
  httpServer,
  config: {
    p3xrs: {
      port: 7843,
      connections: {
        'my-redis': {
          host: 'localhost',
          port: 6379,
          password: process.env.REDIS_PASSWORD ?? ''
        }
      },
      auth: {
        enabled: true,
        username: 'admin',
        password: process.env.UI_PASSWORD ?? 'changeme'
      },
      lang: 'en',
      theme: 'dark-blue',
      ai: {
        provider: 'groq',
        apiKey: process.env.GROQ_API_KEY ?? ''
      }
    }
  }
});

httpServer.listen(7843, () => {
  console.log('P3X Redis UI server running on http://localhost:7843');
});