Introduction:
A website plays a major role in how potential customers discover a brand, explore its services, and decide whether to make an enquiry. Whether you are introducing a new service, launching a campaign, or updating your existing website, getting the right pages live quickly can make a difference.
However, creating website pages often involves multiple steps, from deciding the layout and writing content to coordinating design and development.
AI-powered development tools are changing how this process works. Claude Code, developed by Anthropic, allows users to create and modify websites through natural-language instructions. It can write code, organise project files, generate page layouts, and help resolve development issues.
If you want to build a website with Claude Code, you can use it to create an initial business website, experiment with landing page designs, or develop a dedicated service page without manually writing every line of code.
But can you really build a website in 10 minutes?
You can create a basic website prototype in approximately 10 minutes when your requirements and development environment are ready. A production-ready website, however, requires additional work involving content accuracy, testing, SEO, security, and deployment.
In this guide, we will walk through the complete process of creating a business website using Claude Code, with practical prompts and examples you can adapt to your requirements.
What Is Claude Code and How Does It Work?
Claude Code is an agentic coding tool developed by Anthropic. It works directly with your development environment, allowing you to create, edit, and manage project files using natural-language instructions.
Unlike a conventional AI chatbot that primarily provides code snippets, Claude Code can inspect an existing project, make changes to files, execute development commands, and help identify errors.
For example, imagine you want to create a landing page for a company offering cloud consulting services.
You can instruct Claude Code to:
- Create a landing page explaining the company’s cloud consulting services.
- Add sections highlighting customer challenges and service benefits.
- Include a consultation enquiry form.
- Design clear calls to action that guide visitors towards making an enquiry.
- Ensure the page works across desktop, tablet, and mobile devices.
Claude Code can interpret these requirements, generate the necessary code, and organize the website components.
You can also ask it to review existing website pages, improve specific sections, or investigate technical issues. This makes it useful for initial website creation as well as ongoing website improvements.
For a deeper understanding of its capabilities, explore the official Claude Code documentation.
What Do You Need Before Building a Website With Claude Code?
Before starting your Claude Code website development project, prepare a few essentials. Having these details ready helps the tool understand your requirements and reduces unnecessary revisions.
1. Claude Code access: You need access through an eligible Claude subscription, Anthropic Console API usage, or another supported provider.
2. Node.js: Install Node.js if you are using React with Vite for your website project. It also provides npm for installing dependencies.
3. Terminal: A command-line interface allows you to install Claude Code, create project folders, and run website development commands.
4. Code editor: Visual Studio Code or another code editor can help you inspect and manually modify the generated files.
5. Website requirements: Decide what you want the website to achieve before generating it.
For this tutorial, we will create a landing page for a fictional B2B cloud consulting company.
The page will include:
- A headline communicating the service offering.
- A description explaining the value of the service.
- Sections highlighting customer challenges and solutions.
- Service details and key benefits.
- A consultation CTA.
- An enquiry form.
Also, keep your brand guidelines, preferred colours, existing website content, and service information ready.
If you are new to the tool, follow the official Claude Code installation guide.
How to Build a Website in 10 Minutes With Claude Code
Let’s create a landing page for a fictional company offering cloud consulting services. The objective is to communicate the service offering clearly and encourage relevant visitors to submit an enquiry.
We will use React with Vite to create the website frontend.
Step 1 – Install and Set Up Claude Code
Start by installing Claude Code on your computer.
Open your terminal and use the installation command suitable for your operating system.
For macOS, Linux, or WSL:
curl -fsSL https://claude.ai/install.sh | bash
For Windows PowerShell:
irm https://claude.ai/install.ps1 | iex
Once the installation is complete, verify that Claude Code is available:
claude –version
Next, launch Claude Code:
claude
Follow the authentication instructions to connect your eligible Claude account or configured API access.
Once authentication is complete, Claude Code is ready to work with your local project files.
Step 2 – Create Your Website Project
Before generating the website, create a project folder.
For this tutorial, we will use Vite with React.
Open a terminal and run:
npm create vite@latest cloud-consulting-site — –template react
Move into the newly created project directory:
cd cloud-consulting-site
Install the required dependencies:
npm install
Now start Claude Code from inside this project folder:
claude
This is important because Claude Code uses the current working directory to understand which project files it can access and modify.
You now have a basic React project ready for website creation.
Step 3 – Give Claude Code a Website-Building Prompt
The quality of your website depends heavily on the instructions you provide.
A vague request such as “Create a professional website” leaves too many decisions open. Claude Code may generate a generic layout that does not communicate the actual service offering or encourage visitors to take action.
Instead, provide the business objective, target audience, page structure, content requirements, and design direction.
For our cloud consulting landing page, use this prompt:
Website creation prompt:
Create a responsive landing page for a fictional B2B
company called CloudBridge Solutions.
The company provides cloud migration, cloud consulting,
infrastructure management, and cloud optimisation services.
Primary objective:
Generate relevant enquiries from companies exploring
cloud migration and consulting services.
Target audience:
Companies evaluating cloud infrastructure improvements.
Website structure:
1. Header with company logo, navigation links,
and a Contact Us button.
2. Hero section with a clear headline, supporting
description, and Book a Consultation CTA.
3. Business challenges section explaining common
cloud infrastructure concerns.
4. Services section with four service cards and
concise descriptions.
5. Why Choose Us section highlighting the company’s
approach and service capabilities.
6. Contact section with name, business email,
company name, and requirements fields.
7. Footer with navigation and contact information.
Design requirements:
– Use a professional B2B visual style.
– Use navy blue, white, and a restrained teal accent.
– Maintain clear typography and consistent spacing.
– Make the CTA easy to identify.
– Ensure the layout works on mobile and desktop.
– Avoid excessive animations and generic stock-style layouts.
Technical requirements:
– Use the existing React and Vite project.
– Create reusable React components.
– Keep the code organised.
– Ensure navigation links work.
– Add frontend form validation.
– Do not claim form submissions are stored or emailed
without a backend integration.
First inspect the existing project files.
Then implement the landing page.
Run the production build and fix any errors.
This prompt gives Claude Code a defined purpose, page structure, design direction, and functionality requirements.
You can replace the fictional company details with your actual services and brand information.
For better results, provide clear instructions and review the proposed approach before allowing substantial changes. Explore Anthropic’s Claude Code best practices for additional guidance.
Step 4 – Generate Your Website Structure and Design
After submitting the prompt, Claude Code will inspect the project and begin creating or updating the required files.
For our React project, the generated files may include:
- src/App.jsx – Main application component.
- src/App.css – Website styling.
- src/main.jsx – Application entry point.
- src/components/ – Reusable components for the header, services, contact section, and footer.
Claude Code can generate the page structure, write the content, style the individual sections, and connect the components.
Once the initial version is ready, review whether the content and layout communicate the intended service offering.
If the hero section does not explain the service clearly, for example, use this follow-up prompt:
Review the current hero section.
The headline should communicate the cloud consulting
service more clearly and explain its business relevance.
Improve the headline and supporting description.
Make the primary consultation CTA more prominent.
Keep the existing brand colours and overall layout.
Do not make changes to other website sections.
This helps refine a specific section without unnecessarily changing the entire website.
Step 5 – Run and Preview Your Website
Once Claude Code has generated the website files, preview the result in your browser.
Open a terminal inside the project directory and run:
npm run dev
Vite will start a local development server and display a URL, usually:
http://localhost:5173/
Open this URL in your browser to view the landing page.
Check whether:
- The headline communicates the service clearly.
- Visitors can easily identify the main CTA.
- Service descriptions are accurate and easy to understand.
- Navigation links direct visitors to the correct sections.
- The enquiry form displays and validates correctly.
- The page works across mobile and desktop screens.
If you notice an issue, describe it to Claude Code instead of requesting a complete redesign.
For example:
The consultation CTA is difficult to notice against
the current hero section.
Improve its visual prominence while maintaining
the existing colour palette.
Check the button’s spacing and placement on both
desktop and mobile screens.
Claude Code can inspect the relevant files and make the necessary adjustments.
Step 6 – Improve Your Website Using Follow-Up Prompts
Your first website version is a starting point. Targeted improvements can make the page more useful and consistent with its intended objective.
Here are three practical prompts you can use.
Improve the service messaging:
Review the service descriptions on the landing page.
Make each description specific and easy to understand.
Explain what each service covers and how it addresses a relevant customer requirement.
Avoid repetitive language and unsupported claims.
Keep the descriptions concise.
Improve the conversion path:
Review the landing page from a visitor’s perspective.
Check whether the page clearly communicates the service,
builds an understandable flow between sections,
and guides visitors towards the enquiry form.
Identify unclear content, unnecessary distractions,
and opportunities to improve CTA placement.
Implement the relevant improvements without
changing the brand identity.
Improve mobile responsiveness:
Review the website across mobile, tablet,
and desktop screen sizes.
Identify problems with navigation, text alignment,
images, buttons, and service cards.
Fix the responsive layout while keeping
the existing desktop design consistent.
The key is to refine the website based on specific requirements. Generate, preview, identify gaps, and improve.
How to Test and Optimize Your Website
Creating a website is only the first part of the process. Before publishing it, check whether it works correctly and provides a consistent experience.
Here are four areas to evaluate.
1. Website performance: Check image sizes, unnecessary dependencies, and inefficient code. Use tools such as Google PageSpeed Insights to assess loading performance and identify areas for improvement.
2. Search engine optimisation: Review page titles, meta descriptions, heading structure, image alt text, internal links, and URL structure. Ensure the page content reflects the actual services and relevant search intent.
For a stronger organic search presence, explore professional SEO Services covering technical optimization, keyword research, and content improvements.
3. User experience: Check whether visitors can understand the service offering, navigate between sections, and identify the next step without confusion.
4. Enquiry functionality: Test form validation, required fields, and submission behaviour. A frontend form alone cannot store or deliver enquiries. Connect it to a suitable backend or form service and verify that submissions reach the intended destination.
Also, review website security and accessibility before publishing.
How to Deploy Your Website Online
After testing and optimization, you can publish your website using GitHub and Vercel.
Step 1: Create a GitHub Repository
GitHub allows you to store your website’s source code, track changes, and maintain different project versions.
Follow these steps:
- Sign in to your GitHub account.
- Create a new repository.
- Name it cloud-consulting-site.
- Select the appropriate visibility setting.
- Create the repository.
Refer to the official GitHub documentation for repository creation and management.
Next, open your project terminal and run:
git init
git add .
git commit -m “Initial website creation”
git branch -M main
git remote add origin YOUR_GITHUB_REPOSITORY_URL
git push -u origin main
Replace YOUR_GITHUB_REPOSITORY_URL with the actual URL of your repository.
Make sure you do not commit passwords, API keys, or sensitive configuration files.
Step 2: Connect Your Repository to Vercel
Vercel allows you to deploy frontend projects directly from GitHub.
Follow these steps:
- Visit Vercel and sign in.
- Select Add New Project.
- Connect your GitHub account.
- Import the cloud-consulting-site repository.
- Check the project configuration. Vercel generally detects React and Vite automatically.
- Select Deploy.
Vercel will install the dependencies, run the production build, and publish your website if the build succeeds.
For additional configuration details, refer to the official Vercel documentation.
Step 3: Verify Your Live Website
After deployment, Vercel provides a public URL where visitors can access your website.
Open the URL and review the live version.
Check the navigation, images, mobile layout, enquiry form, and interactive elements. If you have connected a custom domain, verify that it points to the correct deployment.
When you make further changes, push the updated code to GitHub. Vercel can automatically trigger a new deployment.
Common Problems When Building a Website With Claude Code
Although Claude Code can simplify website development, you may encounter a few issues during the process.
| Common problem | How to address it |
| Generic website content | Provide actual service details, customer requirements, and a clear website objective. |
| Inconsistent design | Specify brand colours, typography, spacing, and visual references in your prompt. |
| Inaccurate service information | Supply verified business information and review generated content before publishing. |
| Mobile layout issues | Ask Claude to inspect and correct the responsive CSS at specific screen sizes. |
| Non-functional enquiry forms | Specify the required integration and connect a backend or form service. |
| Deployment errors | Review the build logs and ask Claude to investigate the reported issue. |
| SEO gaps | Request a structured SEO review and manually verify the recommendations. |
One important practice when learning how to use Claude Code is to review its proposed changes rather than approving every action automatically.
Keep your project backed up, inspect dependencies before installing them, and check generated code before publishing. This is particularly important when handling customer information or website integrations.
Conclusion
AI-powered development is changing how websites are created and improved. With Claude Code, you can turn a website brief into an initial working version, generate service pages, experiment with landing page layouts, and make targeted changes using natural-language instructions.
As this tutorial demonstrates, you can build a website with Claude Code and get an initial prototype running in approximately 10 minutes when your requirements and setup are ready.
However, a website’s effectiveness depends on more than how quickly it is developed. Clear service messaging, consistent branding, search visibility, responsive design, and a smooth customer journey all contribute to how well it supports business objectives.
If you want a website that communicates your brand effectively, presents your services clearly, and supports your digital growth objectives, explore Gravitas’ Website Development Services.
You can also explore our Digital Marketing Services to strengthen your online presence, reach relevant audiences, and create better opportunities for business enquiries.
Frequently Asked Questions
Yes. Claude Code allows you to describe website requirements in natural language and generate or modify the required code. However, some understanding of website structure, project setup, and testing will help you manage the process. You should also review the generated output before publishing.
Claude Code is included with eligible paid Claude plans, such as Pro and Max, and is also available through Anthropic Console API usage and supported providers. API usage is billed separately based on consumption. Check the official Claude pricing page for current access and pricing details.
Claude Code can generate a basic website from a detailed prompt, including its layout, content sections, and styling. However, one prompt may not produce a production-ready website. Additional instructions are often needed to refine content, correct design inconsistencies, configure integrations, and test functionality.
Yes. You can instruct Claude Code to create responsive layouts using CSS media queries and other responsive design techniques. However, you should preview the website across different screen sizes and correct any layout issues before publishing.
Yes. Claude Code can assist with Git commands, project preparation, and deployment workflows. You can publish your website using platforms such as Vercel by connecting your GitHub repository. Deployment configuration and final verification are still required.