Guides

How to Use Claude Code: Build a Website and Put It Online (2026)

Short answer: Get Claude Pro ($20 a month), install Claude Code with one command, and type claude in a new folder. Tell it what website to build. Then put the site online with web hosting, from $2.23 a month with our link. It takes about 30 minutes.

See Hostinger web hosting prices

Claude Code is Anthropic’s AI coding agent. You tell it what you want in plain English. It writes the code, runs it and fixes its own mistakes. You don’t need to know how to code. This way of building is called vibe coding.

In this guide you install Claude Code, have it build a small website, and then put that website on the internet. If you’re not sure what Claude Code is yet, read What is Claude Code? first.

What you’ll have at the end

What you need before you start

How much it costs

What Price Notes
Claude Pro $20/mo, or $200 a year Includes Claude Code
Hostinger Unlimited web hosting $2.23/mo ($107.04 for 48 months) With our referral link, checked Nov 11, 2026. Renews at $16.99/mo.
Domain Free for 1 year Comes with the hosting plan

Why Unlimited and not the cheaper plan? Hostinger’s plan page says deploying from an AI coding agent or GitHub needs Unlimited or higher. If you only ever upload plain files by hand, Premium ($1.59 a month) works too.

Part 1: Install Claude Code

Step 1: Open your terminal

The terminal is a window where you type commands.

What you’ll see: a mostly empty window with a blinking cursor.

Step 2: Paste the install command

On a Mac or Linux, paste this and press Enter:

curl -fsSL https://claude.ai/install.sh | bash

On Windows, in PowerShell, paste this and press Enter:

irm https://claude.ai/install.ps1 | iex

This is Anthropic’s official installer.

What you’ll see: nothing for a little while. It shows no progress as it downloads. Wait until the blinking cursor comes back.

Stuck? On Windows, if it says ‘irm’ is not recognized, you opened Command Prompt, not PowerShell. Go back to Step 1 and open PowerShell.

Step 3: Check that it worked

Close the terminal window and open a new one. Then paste this and press Enter:

claude --version

What you’ll see: a version number followed by (Claude Code). That means it’s installed.

Stuck? If it says claude: command not found or not recognized, close every terminal window and open a fresh one. If that doesn’t fix it, Anthropic’s setup page has a fix for this.

Part 2: Sign in and start a project

Step 4: Make a folder for your website

Paste this and press Enter:

mkdir my-site

Then paste this and press Enter:

cd my-site

The first command makes a new, empty folder called my-site. The second one moves you into it. Claude Code works on the folder you’re in.

What you’ll see: nothing new, just a fresh line. That’s normal.

Step 5: Start Claude Code

Paste this and press Enter:

claude

What you’ll see: the first time, Claude Code asks you to log in. Read each question and follow it.

Step 6: Sign in with your Claude account

Pick the option to sign in with your Claude account (Pro, Max or Ultra). A browser tab opens. Log in to Claude there and approve.

What you’ll see: back in the terminal, a box where you can type. Above it, Claude Code shows its version, the model and your folder.

Stuck? If it asks whether you trust this folder, say yes. It’s the empty folder you just made.

Part 3: Build your website

Step 7: Tell Claude Code what to build

Type what you want in plain English and press Enter. Be specific. For example:

Build a one-page website for my dog walking business, "Happy Paws".
Add a header, 3 services with prices, a photo gallery section,
and a contact form. Use plain HTML, CSS and JavaScript.
Make it look good on phones.

Asking for plain HTML, CSS and JavaScript keeps the site simple to put online later.

What you’ll see: Claude Code thinks for a moment, then lists the files it wants to make.

Step 8: Approve the changes

Claude Code asks before it creates or changes files. When it asks, choose Yes.

What you’ll see: it writes each file and tells you what it did. A small site takes a minute or two.

Tip: if you get tired of saying yes, press Shift and Tab together. That changes how much Claude Code can do without asking. Leave it on the default until you’re used to it.

Step 9: Look at your site

Type this and press Enter:

Open the website in my browser so I can see it.

What you’ll see: your new site in a browser tab.

Stuck? If no tab opens, find the my-site folder on your computer and double-click index.html.

Step 10: Ask for changes

Keep talking to Claude Code like a helper. For example:

Make the header green and add a "Book a walk" button that scrolls to the contact form.

Refresh the browser tab to see each change. Ask for as many changes as you like.

Part 4: Put your website online

Your site only lives on your computer so far. To let other people open it, you need hosting (a computer that shows your site to visitors all day).

Step 11: Get a web hosting plan

Open Hostinger’s web hosting page with our discount, and pick the Unlimited plan. You get a free domain for the first year.

Get Hostinger web hosting

Hostinger signs you up and asks you to pay. Do that part yourself.

Step 12: Connect Claude Code to Hostinger

Hostinger has a free add-on called Hostinger Connector. It lets Claude Code work with your Hostinger account. In your terminal, type /exit and press Enter to leave Claude Code. Then paste this and press Enter:

claude mcp add hostinger -- npx -y @hostinger/mcp

What you’ll see: a short message that the hostinger server was added.

Stuck? This command needs Node.js. If you later see npx: command not found, install the LTS version from nodejs.org, open a new terminal, and try again.

Step 13: Ask Claude Code to put the site live

Start Claude Code again with claude. Then type:

Deploy this project to my Hostinger account and make it live on my domain.

What you’ll see: the first time, a browser tab opens for you to sign in to Hostinger. Sign in there yourself. Then Claude Code uploads your site and tells you the web address.

Stuck? If Claude Code says it can’t find a website or domain, open your Hostinger account and finish the setup it asks for first. Then ask again.

Check that it worked

Open the web address Claude Code gave you on your phone, with Wi-Fi turned off. If your site loads and shows a padlock next to the address, it’s live for everyone.

If something went wrong

What you see What it means How to fix it
claude: command not found The terminal can’t find Claude Code yet Close all terminals and open a new one. Then try claude --version again.
Claude Code says you’ve hit a limit You used your plan’s 5-hour amount Wait for it to reset, or turn on usage credits. Our pricing guide explains the limits.
The site looks broken on your phone The design needs work for small screens Tell Claude Code: “The site looks broken on a phone. Fix it.”
npx: command not found Node.js isn’t installed Install the LTS version from nodejs.org, then open a new terminal.
The domain shows an old or empty page The domain is still connecting Wait up to an hour, then check again.

GitHub is a free website that keeps every version of your project. If Claude Code breaks something, you can go back. Hostinger can also deploy your site straight from GitHub. Our Claude Code and GitHub guide shows you how, step by step.

Tips to get better results

FAQ

Is Claude Code free? No. It comes with Claude Pro at $20 a month, or higher plans. The Claude Code program itself is free to install.

Do I need to know how to code? No. You type what you want in plain English. It helps to read what Claude Code tells you, so you know what changed.

Can I use Claude Code without the terminal? Yes. Anthropic’s docs say Claude Code also runs on the web, as a desktop app and in VS Code. This guide uses the terminal because the steps are the same on every computer.

Is Claude Code better than Codex? Both build the same kinds of things and start at $20 a month. Our Codex vs Claude Code comparison shows the differences in price and limits.

Can I build an app with logins or a database? Yes, but those apps usually need a VPS (a computer you rent that stays on all day). Hostinger’s KVM 2 VPS is $7.03 a month for 24 months with our link. Our VPS vs shared hosting guide helps you choose.

Tested by: written by the WebHostCompared team on November 11, 2026, from Anthropic’s and Hostinger’s own setup pages. Prices checked live that day. We haven’t added screenshots of each step yet.

Sources