Hostinger API MCP server

Integrates with Hostinger's hosting platform to enable domain registration and DNS management, VPS creation and configuration, firewall setup, backup operations, and billing subscription handling through over 100 specialized tools organized by service category.
Back to servers
Setup instructions
Provider
Hostinger
Release date
Apr 11, 2025
Stats
40 stars

The Model Context Protocol (MCP) server for Hostinger API allows AI models to interact with Hostinger's services through a standardized interface. It enables automation of various hosting management tasks including domain registration, DNS management, VPS control, and billing operations.

Prerequisites

  • Node.js version 24 or higher

If you don't have Node.js installed, you can download it from the official website.

We recommend using NVM (Node Version Manager) to install and manage Node.js versions:

nvm install v24
nvm use v24

Installation

To install the MCP server, run one of the following commands:

# Install globally from npm
npm install -g hostinger-api-mcp

# Or with yarn
yarn global add hostinger-api-mcp

# Or with pnpm
pnpm add -g hostinger-api-mcp

Update

To update to the latest version:

# Update globally from npm
npm update -g hostinger-api-mcp

# Or with yarn
yarn global upgrade hostinger-api-mcp

# Or with pnpm
pnpm update -g hostinger-api-mcp

Configuration

The following environment variables can be configured:

  • DEBUG: Enable debug logging (true/false) (default: false)
  • API_TOKEN: Your API token, which will be sent in the Authorization header.

Usage

JSON Configuration for Claude, Cursor, etc.

{
    "mcpServers": {
        "hostinger-api": {
            "command": "hostinger-api-mcp",
            "env": {
                "DEBUG": "false",
                "API_TOKEN": "YOUR API TOKEN"
            }
        }
    }
}

Transport Options

The MCP server supports two transport modes:

Standard I/O Transport

The server can use standard input/output (stdio) transport (default). This provides local streaming.

Streamable HTTP Transport

The server can use HTTP streaming transport for bidirectional streaming over HTTP:

# Default HTTP transport on localhost:8100
hostinger-api-mcp --http

# Specify custom host and port
hostinger-api-mcp --http --host 0.0.0.0 --port 8150

Command Line Options

Options:
  --http           Use HTTP streaming transport
  --stdio          Use Server-Sent Events transport (default)
  --host {host}    Hostname or IP address to listen on (default: 127.0.0.1)
  --port {port}    Port to bind to (default: 8100)
  --help           Show help message

Using as an MCP Tool Provider

This server implements the Model Context Protocol (MCP) and can be used with any MCP-compatible consumer.

Example of connecting using HTTP streaming transport:

import { Client } from "@modelcontextprotocol/sdk/client/index.js";
import { StreamableHTTPClientTransport } from "@modelcontextprotocol/sdk/client/streamableHttp.js";

// Create HTTP transport
const transport = new StreamableHTTPClientTransport({
  url: "http://localhost:8100/",
  headers: {
    "Authorization": `Bearer ${process.env.API_TOKEN}`
  }
});

// Connect to the MCP server
const client = new Client({
  name: "my-client",
  version: "1.0.0"
}, {
  capabilities: {}
});

await client.connect(transport);

// List available tools
const { tools } = await client.listTools();
console.log("Available tools:", tools);

// Call a tool
const result = await client.callTool({
  name: "billing_getCatalogItemListV1",
  arguments: { category: "DOMAIN" }
});
console.log("Tool result:", result);

Available Tools

The MCP server provides numerous tools for managing Hostinger services, including:

Domain Management

  • Check domain availability
  • Register new domains
  • Configure DNS records
  • Manage domain forwarding
  • Enable/disable privacy protection
  • Update nameservers

VPS Management

  • Create and configure virtual machines
  • Start/stop/restart VPS instances
  • Create and restore snapshots
  • Install OS templates
  • Configure firewalls
  • Manage Docker projects
  • Monitor system metrics

Billing Operations

  • Get catalog items
  • Create service orders
  • Manage payment methods
  • View subscriptions
  • Enable/disable auto-renewal

Each tool exposes specific functionality with appropriate parameters. Refer to the appropriate tool documentation for detailed parameter information.

How to install this MCP server

For Claude Code

To add this MCP server to Claude Code, run this command in your terminal:

claude mcp add-json "hostinger-api" '{"command":"hostinger-api-mcp","env":{"DEBUG":"false","APITOKEN":"YOUR API TOKEN"}}'

See the official Claude Code MCP documentation for more details.

For Cursor

There are two ways to add an MCP server to Cursor. The most common way is to add the server globally in the ~/.cursor/mcp.json file so that it is available in all of your projects.

If you only need the server in a single project, you can add it to the project instead by creating or adding it to the .cursor/mcp.json file.

Adding an MCP server to Cursor globally

To add a global MCP server go to Cursor Settings > Tools & Integrations and click "New MCP Server".

When you click that button the ~/.cursor/mcp.json file will be opened and you can add your server like this:

{
    "mcpServers": {
        "hostinger-api": {
            "command": "hostinger-api-mcp",
            "env": {
                "DEBUG": "false",
                "APITOKEN": "YOUR API TOKEN"
            }
        }
    }
}

Adding an MCP server to a project

To add an MCP server to a project you can create a new .cursor/mcp.json file or add it to the existing one. This will look exactly the same as the global MCP server example above.

How to use the MCP server

Once the server is installed, you might need to head back to Settings > MCP and click the refresh button.

The Cursor agent will then be able to see the available tools the added MCP server has available and will call them when it needs to.

You can also explicitly ask the agent to use the tool by mentioning the tool name and describing what the function does.

For Claude Desktop

To add this MCP server to Claude Desktop:

1. Find your configuration file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json

2. Add this to your configuration file:

{
    "mcpServers": {
        "hostinger-api": {
            "command": "hostinger-api-mcp",
            "env": {
                "DEBUG": "false",
                "APITOKEN": "YOUR API TOKEN"
            }
        }
    }
}

3. Restart Claude Desktop for the changes to take effect

Want to 10x your AI skills?

Get a free account and learn to code + market your apps using AI (with or without vibes!).

Nah, maybe later