{"id":127786,"date":"2025-05-06T08:30:04","date_gmt":"2025-05-06T08:30:04","guid":{"rendered":"\/tutorials\/?p=127786"},"modified":"2026-03-09T19:16:36","modified_gmt":"2026-03-09T19:16:36","slug":"how-to-run-hostinger-api-mcp-server","status":"publish","type":"post","link":"\/ng\/tutorials\/how-to-run-hostinger-api-mcp-server\/","title":{"rendered":"How to run your own Hostinger API MCP server"},"content":{"rendered":"<?xml encoding=\"utf-8\" ?><p>Hostinger provides an application programming interface (API) that lets you interact programmatically with your hosting account and VPS. This enables you to integrate your account with external services.<\/p><p>For example, you can create a Model Context Protocol (MCP) server and connect the Hostinger API to leverage AI in your hosting management tasks.<\/p><p>In this article, we&rsquo;ll explain how to set up an MCP server and connect it with the Hostinger API. We&rsquo;ll also go over the prerequisites to ensure a smooth configuration process.<\/p><p>\n\n\n\n<\/p><h2 class=\"wp-block-heading\" id=\"h-what-is-an-mcp-server\"><strong>What is an MCP server?<\/strong><\/h2><p>MCP is a communication protocol that provides AI agents with a standardized way to integrate and exchange data with various external tools or services.<\/p><p>Meanwhile, an MCP server is an entity that provides tools, prompts, or data resources to the AI agents via the MCP. In a real-world scenario, it gives <a href=\"\/ng\/tutorials\/cursor-alternatives\/\">applications like Cursor<\/a> access to information from other sources, like your email inbox.<\/p><p>Setting up an MCP server can allow the Hostinger API to provide tools for your AI agent. This enables the AI agent to access your hosting account and perform tasks like fetching information or managing services.<\/p><p>        <div class=\"protip\">\n            <div class=\"protip__heading\">\n                <svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\">\n                    <path d=\"M1.49234 23.5024C1.23229 23.5024 0.972242 23.4024 0.782206 23.2123C0.562165 22.9923 0.452144 22.6822 0.502153 22.3722C0.562165 21.9221 1.14227 17.9113 3.00262 16.351C3.63274 15.8209 4.43289 15.5509 5.26305 15.5609C6.09321 15.5909 6.87335 15.9109 7.47347 16.4911C8.6937 17.6913 8.76371 19.6717 7.6435 20.9919C6.0832 22.8523 2.08245 23.4324 1.63237 23.4924C1.59236 23.4924 1.54235 23.4924 1.50234 23.4924L1.49234 23.5024ZM5.16303 17.5613C4.84297 17.5613 4.53291 17.6713 4.29287 17.8813C3.60274 18.4614 3.07264 19.9317 2.75258 21.242C4.06282 20.9219 5.5331 20.3918 6.11321 19.7017C6.55329 19.1716 6.54329 18.3814 6.0832 17.9213C5.85316 17.7013 5.5431 17.5713 5.20304 17.5613C5.19304 17.5613 5.17303 17.5613 5.16303 17.5613ZM11.7243 21.8821C11.4942 21.8821 11.2642 21.8021 11.0841 21.652C10.8541 21.462 10.7241 21.1819 10.7241 20.8819V15.9109L8.08358 13.2705H3.11264C2.81259 13.2705 2.53254 13.1404 2.3425 12.9104C2.15246 12.6803 2.07245 12.3803 2.12246 12.0902C2.19247 11.7102 2.84259 8.36953 4.70294 7.12929C6.33325 6.04909 8.96375 6.49918 10.244 6.80923C11.5442 4.96889 13.2546 3.4286 15.2349 2.33839C17.4553 1.11816 19.9858 0.518051 22.4963 0.498047C23.0464 0.498047 23.4865 0.948132 23.4865 1.49824C23.4865 5.0389 22.3763 9.97983 17.1753 13.7605C17.4853 15.0408 17.9354 17.6613 16.8552 19.2816C15.615 21.1419 12.2744 21.7921 11.8943 21.8621C11.8343 21.8721 11.7743 21.8821 11.7143 21.8821H11.7243ZM12.7245 16.181V19.6016C13.7146 19.2916 14.7948 18.7915 15.2049 18.1814C15.675 17.4812 15.605 16.091 15.385 14.9008C14.5248 15.3808 13.6346 15.8109 12.7245 16.181ZM9.66388 12.0302L11.9643 14.3307C13.1845 13.8306 14.3648 13.2204 15.485 12.5103C19.9358 9.51974 21.2361 5.60901 21.4561 2.53843C19.6157 2.67846 17.8254 3.20856 16.2051 4.09872C14.2847 5.14892 12.6544 6.68921 11.4942 8.54956C10.7841 9.65977 10.174 10.82 9.66388 12.0302ZM4.39289 11.2701H7.81353C8.1936 10.3599 8.63368 9.46974 9.11377 8.60957C7.92355 8.38953 6.51329 8.31952 5.81315 8.78961C5.19304 9.19968 4.70294 10.3099 4.39289 11.2701Z\" fill=\"#673DE6\"\/>\n                <\/svg>\n                <p class=\"protip__title\">\n                    Did you know?                <\/p>\n            <\/div>\n            <p class=\"protip__content\"><strong>Kodee<\/strong>, Hostinger's AI assistant, is powered with MCP. This enables it to handle various tasks beyond traditional chatbots, including managing <a href=\"\/ng\/tutorials\/wordpress-mcp-integration\/\">WordPress site through MCP<\/a> and various aspects of your VPS like firewall, SSH keys, or snapshots, all through chat.<\/p>\n                    <\/div>\n        \n\n\n\n<\/p><h2 class=\"wp-block-heading\" id=\"h-prerequisites\"><strong>Prerequisites<\/strong><\/h2><p>To set up the MCP server at Hostinger, you only need to <a href=\"https:\/\/auth.hostinger.com\/register\">create an account in hPanel<\/a>. You will use this account to generate the Hostinger API key, which we will explain how to do later. <\/p><p>Then, install the AI agent you want to connect to the MCP server on your local system. The tool will differ depending on what you want to achieve with the integration. For this tutorial, we will use Claude Desktop.<\/p><p><div class=\"announcement-block announcement-block--important\">\n            <span class=\"announcement-block__heading\">\n                <svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\">\n                    <path fill-rule=\"evenodd\" clip-rule=\"evenodd\"\n                          d=\"M12 22.5C17.799 22.5 22.5 17.799 22.5 12C22.5 6.20101 17.799 1.5 12 1.5C6.20101 1.5 1.5 6.20101 1.5 12C1.5 17.799 6.20101 22.5 12 22.5ZM13.637 7.65198C13.637 6.74791 12.9041 6.01501 12 6.01501C11.0959 6.01501 10.363 6.74791 10.363 7.65198C10.5335 9.53749 10.875 13.383 10.875 13.383C10.875 14.0043 11.3787 14.508 12 14.508C12.6213 14.508 13.125 14.0043 13.125 13.383V13.38L13.637 7.65198ZM11.9927 15.714C11.3714 15.714 10.8677 16.2177 10.8677 16.839C10.8677 17.4603 11.3714 17.964 11.9927 17.964H12.0073C12.6286 17.964 13.1323 17.4603 13.1323 16.839C13.1323 16.2177 12.6286 15.714 12.0073 15.714H11.9927Z\"\n                          fill=\"#FEA419\"\/>\n                <\/svg>\n                Important\n            <\/span>\n            <p class=\"announcement-block__content\">\n                <strong>Important!<\/strong> Make sure the AI agent you want to integrate with your Hostinger API supports MCP. Check the tool&rsquo;s documentation to learn more about its compatibility.\n            <\/p><\/div>\n\n\n\n<\/p><h2 class=\"wp-block-heading\" id=\"h-setting-up-a-hostinger-api-mcp-server\"><strong>Setting up a Hostinger API MCP server<\/strong><\/h2><p>Here are the steps to set up a Hostinger API MCP server. We&rsquo;ll explain how to configure it on a local computer running macOS, Linux, or Windows.<\/p><h3 class=\"wp-block-heading\" id=\"h-1-install-node-js-and-the-mcp-server-cli\"><strong>1. Install Node.js and the MCP server CLI<\/strong><\/h3><p><a href=\"http:\/\/node.js\">Node.js is an important component<\/a> that enables the MCP server&rsquo;s functionality. Depending on the operating system, the steps to install it vary. For Linux and macOS, here&rsquo;s how to do it:<\/p><ol class=\"wp-block-list\">\n<li>Open your system terminal.<\/li>\n\n\n\n<li>Run the following command to configure the Node Version Manager (NVM), a tool that lets you install and use different versions of Node.js:<\/li>\n<\/ol><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">curl -o- https:\/\/raw.githubusercontent.com\/nvm-sh\/nvm\/v0.39.7\/install.sh | bash<\/pre><ol start=\"3\" class=\"wp-block-list\">\n<li>Reload your system&rsquo;s shell to ensure we can run NVM:<\/li>\n<\/ol><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">source ~\/.bashrc<\/pre><ol start=\"4\" class=\"wp-block-list\">\n<li>Install Node.js via NVM. Note that MCP needs Node.js version 20 or later:<\/li>\n<\/ol><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">nvm install 20<\/pre><ol start=\"5\" class=\"wp-block-list\">\n<li>Set Node.js version 20 as the default for your system using the following command:<\/li>\n<\/ol><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">nvm use 20<\/pre><p>If you&rsquo;re on Windows, the easiest way to <a href=\"\/ng\/tutorials\/how-to-install-nodejs-ubuntu\/\">install Node.js<\/a> is by using the installer package. Download it from the <a href=\"https:\/\/nodejs.org\/en\/download\">official Node.js page<\/a> and run the configuration wizard.<\/p><p>After installing Node.js, configure the MCP server CLI application on your computer. Here&rsquo;s how to install it using NPM, regardless of the operating system you use:<\/p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">npm install -g hostinger-api-mcp<\/pre><h3 class=\"wp-block-heading\" id=\"h-2-generate-a-hostinger-api-token\"><strong>2. Generate a Hostinger API token<\/strong><\/h3><p>An API token enables your Hostinger account to integrate with and authorize your MCP server. Here&rsquo;s how to generate it:<\/p><ol class=\"wp-block-list\">\n<li>On <strong>hPanel<\/strong>, click your <strong>Profile <\/strong>icon and select <strong>Account Information<\/strong>.<\/li>\n<\/ol><div class=\"wp-block-image\"><figure data-wp-context='{\"imageId\":\"6a587478d7e91\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6a587478d7e91\" class=\"aligncenter size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1192\" height=\"584\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/account-information-button-on-hpanel-account-management-menu.png\/w=1024,h=1024,fit=scale-down\" alt=\"Account information button on hPanel's account management menu\" class=\"wp-image-127792\" srcset=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/account-information-button-on-hpanel-account-management-menu.png\/w=1192,fit=scale-down 1192w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/account-information-button-on-hpanel-account-management-menu.png\/w=300,fit=scale-down 300w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/account-information-button-on-hpanel-account-management-menu.png\/w=1024,fit=scale-down 1024w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/account-information-button-on-hpanel-account-management-menu.png\/w=150,fit=scale-down 150w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/account-information-button-on-hpanel-account-management-menu.png\/w=768,fit=scale-down 768w\" sizes=\"auto, (max-width: 1192px) 100vw, 1192px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" aria-label=\"Enlarge\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.imageButtonRight\" data-wp-style--top=\"state.imageButtonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div><ol start=\"2\" class=\"wp-block-list\">\n<li>Navigate to the sidebar and select <strong>API<\/strong>.&nbsp;<\/li>\n\n\n\n<li>Click <strong>Generate token<\/strong> or <strong>New token<\/strong>.<\/li>\n\n\n\n<li>Enter your token name and select an expiration date. Click <strong>Generate<\/strong>.&nbsp;<\/li>\n<\/ol><div class=\"wp-block-image\"><figure data-wp-context='{\"imageId\":\"6a587478dac2f\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6a587478dac2f\" class=\"aligncenter size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1076\" height=\"556\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-token-creation-window.png\/w=1024,h=1024,fit=scale-down\" alt=\"Hostinger API token creation window\" class=\"wp-image-127793\" srcset=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-token-creation-window.png\/w=1076,fit=scale-down 1076w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-token-creation-window.png\/w=300,fit=scale-down 300w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-token-creation-window.png\/w=1024,fit=scale-down 1024w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-token-creation-window.png\/w=150,fit=scale-down 150w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-token-creation-window.png\/w=768,fit=scale-down 768w\" sizes=\"auto, (max-width: 1076px) 100vw, 1076px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" aria-label=\"Enlarge\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.imageButtonRight\" data-wp-style--top=\"state.imageButtonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div><ol start=\"5\" class=\"wp-block-list\">\n<li>Copy your API token and store it in a safe location. Remember, you <strong>won&rsquo;t be able to access it again <\/strong>after closing the API menu.&nbsp;<\/li>\n<\/ol><p><div class=\"announcement-block announcement-block--important\">\n            <span class=\"announcement-block__heading\">\n                <svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\">\n                    <path fill-rule=\"evenodd\" clip-rule=\"evenodd\"\n                          d=\"M12 22.5C17.799 22.5 22.5 17.799 22.5 12C22.5 6.20101 17.799 1.5 12 1.5C6.20101 1.5 1.5 6.20101 1.5 12C1.5 17.799 6.20101 22.5 12 22.5ZM13.637 7.65198C13.637 6.74791 12.9041 6.01501 12 6.01501C11.0959 6.01501 10.363 6.74791 10.363 7.65198C10.5335 9.53749 10.875 13.383 10.875 13.383C10.875 14.0043 11.3787 14.508 12 14.508C12.6213 14.508 13.125 14.0043 13.125 13.383V13.38L13.637 7.65198ZM11.9927 15.714C11.3714 15.714 10.8677 16.2177 10.8677 16.839C10.8677 17.4603 11.3714 17.964 11.9927 17.964H12.0073C12.6286 17.964 13.1323 17.4603 13.1323 16.839C13.1323 16.2177 12.6286 15.714 12.0073 15.714H11.9927Z\"\n                          fill=\"#FEA419\"\/>\n                <\/svg>\n                Important\n            <\/span>\n            <p class=\"announcement-block__content\">\n                <strong>Important!<\/strong> Avoid choosing an overly long expiration date for your API key because it can expose your Hostinger account to security risks in the long term. A short token lifetime requires you to update it periodically.\n            <\/p><\/div>\n\n\n\n<\/p><p>You should test a token&rsquo;s availability and reachability after creating it. To do this, run the cURL command provided at the bottom of your API key generation page.<\/p><p>If the test is successful, you&rsquo;ll see information about your hosting account in the terminal.<\/p><div class=\"wp-block-image\"><figure data-wp-context='{\"imageId\":\"6a587478dda49\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6a587478dda49\" class=\"aligncenter size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1764\" height=\"202\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/terminal-outputs-information-about-hostinger-hosting-account.png\/w=1024,h=1024,fit=scale-down\" alt=\"Terminal outputs information about Hostinger hosting account via API\" class=\"wp-image-127794\" srcset=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/terminal-outputs-information-about-hostinger-hosting-account.png\/w=1764,fit=scale-down 1764w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/terminal-outputs-information-about-hostinger-hosting-account.png\/w=300,fit=scale-down 300w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/terminal-outputs-information-about-hostinger-hosting-account.png\/w=1024,fit=scale-down 1024w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/terminal-outputs-information-about-hostinger-hosting-account.png\/w=150,fit=scale-down 150w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/terminal-outputs-information-about-hostinger-hosting-account.png\/w=768,fit=scale-down 768w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/terminal-outputs-information-about-hostinger-hosting-account.png\/w=1536,fit=scale-down 1536w\" sizes=\"auto, (max-width: 1764px) 100vw, 1764px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" aria-label=\"Enlarge\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.imageButtonRight\" data-wp-style--top=\"state.imageButtonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div><h3 class=\"wp-block-heading\" id=\"h-3-set-up-ai-agent-integration\"><strong>3. Set up AI agent Integration<\/strong><\/h3><p>Once the Hostinger MCP server is set, you&rsquo;ll need to connect it to your AI agent. The steps will differ depending on your AI tool. In this tutorial, we&rsquo;ll show you how to do it on Claude Desktop:<\/p><ol class=\"wp-block-list\">\n<li><a href=\"https:\/\/claude.ai\/download\">Download Claude Desktop<\/a> and log in to your Anthropic account.&nbsp;<\/li>\n\n\n\n<li>Navigate to the menu bar &rarr; <strong>Claude<\/strong> &rarr; <strong>Settings<\/strong>. If you&rsquo;re on Windows, go to the <strong>burger<\/strong> icon at the top left menu &rarr; <strong>File <\/strong>&rarr; <strong>Settings<\/strong>.<\/li>\n<\/ol><div class=\"wp-block-image\"><figure data-wp-context='{\"imageId\":\"6a587478e0867\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6a587478e0867\" class=\"aligncenter size-full wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"748\" height=\"378\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-settings-menu-location.png\/public\" alt=\"Claude settings menu location\" class=\"wp-image-127795\" srcset=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-settings-menu-location.png\/w=748,fit=scale-down 748w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-settings-menu-location.png\/w=300,fit=scale-down 300w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-settings-menu-location.png\/w=150,fit=scale-down 150w\" sizes=\"auto, (max-width: 748px) 100vw, 748px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" aria-label=\"Enlarge\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.imageButtonRight\" data-wp-style--top=\"state.imageButtonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div><ol start=\"3\" class=\"wp-block-list\">\n<li>Click the <strong>Developer<\/strong> tab and click <strong>Edit Config<\/strong>.&nbsp;<\/li>\n\n\n\n<li>You will see the <strong>claude_desktop_config.json<\/strong> file in your file explorer. Open it using a text editor.<\/li>\n\n\n\n<li>Add the following configuration. Replace <strong>YOUR API TOKEN <\/strong>with the Hostinger API key you created earlier, which Claude will send in its authorization header:<\/li>\n<\/ol><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">{\n  \"mcpServers\": {\n    \"hostinger-api\": {\n      \"command\": \"hostinger-api-mcp\",\n      \"env\": {\n        \"DEBUG\": \"false\",\n        \"APITOKEN\": \"YOUR API TOKEN\"\n      }\n    }\n  }\n}<\/pre><ol start=\"6\" class=\"wp-block-list\">\n<li>Save the <strong>JSON<\/strong> file and restart Claude Desktop. If you go to the Developer menu, you should see your Hostinger API listed as <strong>running<\/strong>.&nbsp;<\/li>\n<\/ol><div class=\"wp-block-image\"><figure data-wp-context='{\"imageId\":\"6a587478e32da\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6a587478e32da\" class=\"aligncenter size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1584\" height=\"1106\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-mcp-server-status-in-claude.png\/w=1024,h=1024,fit=scale-down\" alt=\"Hostinger API MCP server status in Claude\" class=\"wp-image-127796\" srcset=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-mcp-server-status-in-claude.png\/w=1584,fit=scale-down 1584w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-mcp-server-status-in-claude.png\/w=300,fit=scale-down 300w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-mcp-server-status-in-claude.png\/w=1024,fit=scale-down 1024w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-mcp-server-status-in-claude.png\/w=150,fit=scale-down 150w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-mcp-server-status-in-claude.png\/w=768,fit=scale-down 768w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/hostinger-api-mcp-server-status-in-claude.png\/w=1536,fit=scale-down 1536w\" sizes=\"auto, (max-width: 1584px) 100vw, 1584px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" aria-label=\"Enlarge\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.imageButtonRight\" data-wp-style--top=\"state.imageButtonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div><h3 class=\"wp-block-heading\" id=\"h-4-test-the-mcp-and-api-connection\"><strong>4. Test the MCP and API connection<\/strong><\/h3><p>Once the MCP server deployment is completed, test the API by requesting information from your AI agents. Hostinger API can manage various aspects of your hosting account, including:<\/p><ul class=\"wp-block-list\">\n<li><strong>Domain names <\/strong>&ndash; enables you to register a domain, list the previously purchased ones, query WHOIS information, and manage forwarding data.&nbsp;<\/li>\n\n\n\n<li><strong>DNS<\/strong> &ndash; lets you update, delete, validate, and reset DNS records for your domains. Also, you can create, check, and restore DNS snapshots.&nbsp;<\/li>\n\n\n\n<li><strong>VPS<\/strong> &ndash; allows you to manage all aspects of your server, including <a href=\"\/ng\/vps-hosting\">purchasing a new VPS plan<\/a>, recovering data from a backup, listing data center locations, summarizing Monarx malware scanner reports, changing credentials, installing OS templates, and more.<\/li>\n\n\n\n<li><strong>Account and ordering <\/strong>&ndash; streamlines account management and the purchase process. For example, you can check available products to buy, place an order, and change the default account payment method.&nbsp;<\/li>\n<\/ul><figure class=\"wp-block-image size-large\"><a class=\"hgr-tutorials-cta hgr-tutorials-cta-vps-hosting\" href=\"\/ng\/vps-hosting\" target=\"_blank\" rel=\"noreferrer noopener\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"300\" src=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2023\/02\/VPS-hosting-banner.png\/w=1024,h=1024,fit=scale-down\" alt=\"\" class=\"wp-image-77934\" srcset=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2023\/02\/VPS-hosting-banner.png\/w=1024,fit=scale-down 1024w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2023\/02\/VPS-hosting-banner.png\/w=300,fit=scale-down 300w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2023\/02\/VPS-hosting-banner.png\/w=150,fit=scale-down 150w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2023\/02\/VPS-hosting-banner.png\/w=768,fit=scale-down 768w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure><p>Checking the MCP API server functionality is as simple as asking the AI agent to check or manage your hosting account. For example, you can use prompts such as:<\/p><pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\" data-enlighter-theme=\"atomic\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">What&rsquo;s the uptime of my newest VPS?\nCheck the hardware usage of my newest VPS.<\/pre><p>Your AI agent will query the API and provide the appropriate information. Receiving a reply means the MCP API server works properly.<\/p><div class=\"wp-block-image\"><figure data-wp-context='{\"imageId\":\"6a587478e7297\"}' data-wp-interactive=\"core\/image\" data-wp-key=\"6a587478e7297\" class=\"aligncenter size-large wp-lightbox-container\"><img loading=\"lazy\" decoding=\"async\" width=\"1460\" height=\"775\" data-wp-class--hide=\"state.isContentHidden\" data-wp-class--show=\"state.isContentVisible\" data-wp-init=\"callbacks.setButtonStyles\" data-wp-on--click=\"actions.showLightbox\" data-wp-on--load=\"callbacks.setButtonStyles\" data-wp-on-window--resize=\"callbacks.setButtonStyles\" src=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-checks-hostinger-vps-uptime.png\/w=1024,h=1024,fit=scale-down\" alt=\"Claude checks hostinger VPS uptime\" class=\"wp-image-127798\" srcset=\"https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-checks-hostinger-vps-uptime.png\/w=1460,fit=scale-down 1460w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-checks-hostinger-vps-uptime.png\/w=300,fit=scale-down 300w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-checks-hostinger-vps-uptime.png\/w=1024,fit=scale-down 1024w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-checks-hostinger-vps-uptime.png\/w=150,fit=scale-down 150w, https:\/\/imagedelivery.net\/LqiWLm-3MGbYHtFuUbcBtA\/wp-content\/uploads\/sites\/2\/2025\/05\/claude-checks-hostinger-vps-uptime.png\/w=768,fit=scale-down 768w\" sizes=\"auto, (max-width: 1460px) 100vw, 1460px\" \/><button class=\"lightbox-trigger\" type=\"button\" aria-haspopup=\"dialog\" aria-label=\"Enlarge\" data-wp-init=\"callbacks.initTriggerButton\" data-wp-on--click=\"actions.showLightbox\" data-wp-style--right=\"state.imageButtonRight\" data-wp-style--top=\"state.imageButtonTop\">\n\t\t\t<svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"12\" height=\"12\" fill=\"none\" viewbox=\"0 0 12 12\">\n\t\t\t\t<path fill=\"#fff\" d=\"M2 0a2 2 0 0 0-2 2v2h1.5V2a.5.5 0 0 1 .5-.5h2V0H2Zm2 10.5H2a.5.5 0 0 1-.5-.5V8H0v2a2 2 0 0 0 2 2h2v-1.5ZM8 12v-1.5h2a.5.5 0 0 0 .5-.5V8H12v2a2 2 0 0 1-2 2H8Zm2-12a2 2 0 0 1 2 2v2h-1.5V2a.5.5 0 0 0-.5-.5H8V0h2Z\"><\/path>\n\t\t\t<\/svg>\n\t\t<\/button><\/figure><\/div><h2 class=\"wp-block-heading\" id=\"h-conclusion\"><strong>Conclusion<\/strong><\/h2><p>MCP enables seamless integration between various tools and AI agents like Claude Desktop. Connecting it with the Hostinger API enables you to manage different aspects of your hosting account using AI prompts, making the process more efficient and streamlined.<\/p><p>Here&rsquo;s how to set up an MCP server with the Hostinger API:<\/p><ol class=\"wp-block-list\">\n<li>&nbsp;Install Node.js and the Hostinger MCP server CLI on your computer.<\/li>\n\n\n\n<li>Generate a Hostinger API key from your account management page in hPanel.<\/li>\n\n\n\n<li>Set up your AI agent by adding the API token to its configuration file.&nbsp;<\/li>\n\n\n\n<li>Test the MCP and API connection by asking your AI agent to perform a task.&nbsp;<\/li>\n<\/ol><p>That&rsquo;s it! Once the integration is complete, you can start using the AI agent to manage your hosting account, whether it is purchasing a domain, changing the default payment method, or checking your VPS uptime.<\/p><h2 class=\"wp-block-heading\" id=\"h-how-to-run-the-hostinger-api-mcp-server-faq\"><strong>How to run the Hostinger API MCP server FAQ<\/strong><\/h2><div class=\"schema-faq wp-block-yoast-faq-block\"><div class=\"schema-faq-section\" id=\"faq-question-1746519134796\"><h3 class=\"schema-faq-question\"><strong>What is MCP?<\/strong><\/h3> <p class=\"schema-faq-answer\">The Model Context Protocol (MCP) is a standardized connection method that enables AI agents to connect and exchange data with various external services. It streamlines integration by eliminating the need to write different functions for multiple services and LLMs.<br>For example, you can connect Gmail with Claude Desktop via MCP to allow the AI tool to access your inbox.&nbsp;<\/p> <\/div> <div class=\"schema-faq-section\" id=\"faq-question-1746519156669\"><h3 class=\"schema-faq-question\"><strong>Why should I use Hostinger API with my MCP server?<\/strong><\/h3> <p class=\"schema-faq-answer\">Connecting the Hostinger API to an MCP server lets you connect various AI tools to your hosting account. This integration allows you to automate tasks that would otherwise require direct interaction via the account management dashboard, saving time and effort. For example, integrating Claude Desktop lets you ask the AI agent to fetch information from your server for a quick monitoring check.<\/p> <\/div> <div class=\"schema-faq-section\" id=\"faq-question-1746519167287\"><h3 class=\"schema-faq-question\"><strong>Do I need advanced technical skills to set up the MCP server with Hostinger API?<\/strong><\/h3> <p class=\"schema-faq-answer\">No, setting up an MCP server with Hostinger API only requires basic technical skills &ndash; the process is very straightforward. You only need to install Node.js and the MCP server CLI on your local computer. Then, configure your AI agent to connect to your Hostinger API.<\/p> <\/div> <\/div>\n","protected":false},"excerpt":{"rendered":"<p>Hostinger provides an application programming interface (API) that lets you interact programmatically with your hosting account and VPS. This enables you to integrate your account with external services. For example, you can create a Model Context Protocol (MCP) server and connect the Hostinger API to leverage AI in your hosting management tasks. In this article, [&#8230;]<\/p>\n<p><a class=\"btn btn-secondary understrap-read-more-link\" href=\"\/ng\/tutorials\/how-to-run-hostinger-api-mcp-server\/\">Read More&#8230;<\/a><\/p>\n","protected":false},"author":337,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"rank_math_title":"How to run Hostinger API MCP server","rank_math_description":"Here\u2019s how to run Hostinger API MCP server: 1. Install Node.js; 2. Install the MCP server CLI application; 3. Configure the MCP server + more.","rank_math_focus_keyword":"how to run Hostinger API MCP server","footnotes":""},"categories":[22644],"tags":[],"class_list":["post-127786","post","type-post","status-publish","format-standard","hentry","category-vps"],"hreflangs":[{"locale":"en-US","link":"https:\/\/www.hostinger.com\/tutorials\/how-to-run-hostinger-api-mcp-server","default":0},{"locale":"en-IN","link":"https:\/\/www.hostinger.com\/in\/tutorials\/how-to-run-hostinger-api-mcp-server","default":0},{"locale":"en-CA","link":"https:\/\/www.hostinger.com\/ca\/tutorials\/how-to-run-hostinger-api-mcp-server","default":0},{"locale":"en-GB","link":"https:\/\/www.hostinger.com\/uk\/tutorials\/how-to-run-hostinger-api-mcp-server","default":0},{"locale":"en-PH","link":"https:\/\/www.hostinger.com\/ph\/tutorials\/how-to-run-hostinger-api-mcp-server","default":0},{"locale":"en-MY","link":"https:\/\/www.hostinger.com\/my\/tutorials\/how-to-run-hostinger-api-mcp-server","default":0},{"locale":"en-AU","link":"https:\/\/www.hostinger.com\/au\/tutorials\/how-to-run-hostinger-api-mcp-server","default":0},{"locale":"en-NG","link":"https:\/\/www.hostinger.com\/ng\/tutorials\/how-to-run-hostinger-api-mcp-server","default":0}],"_links":{"self":[{"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/posts\/127786","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/users\/337"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/comments?post=127786"}],"version-history":[{"count":12,"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/posts\/127786\/revisions"}],"predecessor-version":[{"id":143320,"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/posts\/127786\/revisions\/143320"}],"wp:attachment":[{"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/media?parent=127786"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/categories?post=127786"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hostinger.com\/ng\/tutorials\/wp-json\/wp\/v2\/tags?post=127786"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}