Ai Coding Tools

How to Build a Basic App Using GitHub Copilot in 2 Hours

By BTW Team3 min read

How to Build a Basic App Using GitHub Copilot in 2 Hours

Building a web application can feel like a daunting task, especially if you’re a solo founder or indie hacker juggling multiple responsibilities. The good news is that with tools like GitHub Copilot, you can significantly speed up the development process. In this guide, I’ll show you how to build a basic app using GitHub Copilot in about 2 hours.

Prerequisites

Before diving in, make sure you have the following:

  • GitHub Account: You’ll need this to use Copilot.
  • Visual Studio Code: This is where you’ll write your code.
  • GitHub Copilot Subscription: Costs $10/month, but you can start with a free trial.
  • Basic Understanding of JavaScript: Familiarity with the language will help, but Copilot can assist even beginners.

Step 1: Setting Up Your Environment

  • Install Visual Studio Code: Download and install from here.
  • Install GitHub Copilot: Go to the Extensions tab in VS Code, search for "GitHub Copilot," and install it.

Expected Output: After installation, you should see a Copilot icon in the toolbar.

Step 2: Create a New Repository

  1. Go to GitHub and create a new repository named basic-app.
  2. Clone the repository to your local machine using:
    git clone https://github.com/yourusername/basic-app.git
    
  3. Open the project in Visual Studio Code.

Expected Output: The cloned repository should display in your editor.

Step 3: Start Coding with Copilot

  1. Create an index.html file and start typing the HTML structure. Copilot will suggest completions.

    <!DOCTYPE html>
    <html lang="en">
    <head>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <title>Basic App</title>
    </head>
    <body>
        <h1>Hello, World!</h1>
    </body>
    </html>
    

    Expected Output: You should see a basic HTML template with suggestions from Copilot.

  2. Create a script.js file and let Copilot help with JavaScript functions. Start typing:

    function greet() {
        alert('Welcome to the Basic App!');
    }
    

    Expected Output: Copilot should suggest the complete function as you type.

Step 4: Run Your App

  1. Open a terminal in Visual Studio Code and use the Live Server extension to view your app.
  2. Install Live Server from the Extensions tab if you haven’t done so already.
  3. Right-click index.html and select "Open with Live Server."

Expected Output: Your app should now be running in the browser, displaying "Hello, World!" and greeting you upon page load.

Troubleshooting

  • Copilot Not Suggesting Code: Make sure you are connected to the internet and signed in to GitHub.
  • Live Server Not Starting: Check if the Live Server extension is installed and that you are opening the correct HTML file.

What’s Next?

Now that you have a basic app, consider adding features like a form, API calls, or even a database connection. Use Copilot to help with these enhancements, and don’t hesitate to iterate on your project.

Conclusion

Using GitHub Copilot, building a basic app in 2 hours is not just feasible but also a learning experience. If you’re new to coding or want to speed up your development process, start with Copilot.

Our Recommendation: Dive into GitHub Copilot with a focus on small projects. It’s especially useful for iterating quickly on ideas without getting bogged down in syntax and boilerplate code.

Follow Our Building Journey

Weekly podcast episodes on tools we're testing, products we're shipping, and lessons from building in public.

Subscribe

Never miss an episode

Subscribe to Built This Week for weekly insights on AI tools, product building, and startup lessons from Ryz Labs.

Subscribe
Ai Coding Tools

10 AI Coding Tools That Will Drastically Reduce Your Debugging Time

10 AI Coding Tools That Will Drastically Reduce Your Debugging Time As a developer, whether you're just starting out or have years of experience, debugging can feel like a neverend

Oct 16, 20265 min read
Ai Coding Tools

10 Common Mistakes When Integrating AI Coding Tools into Your Workflow

10 Common Mistakes When Integrating AI Coding Tools into Your Workflow As developers, we’re always on the lookout for ways to streamline our workflow and boost productivity. Enter

Oct 14, 20264 min read
Ai Coding Tools

5 Myths About AI Coding Tools That Could Hurt Your Development Process

5 Myths About AI Coding Tools That Could Hurt Your Development Process As a solo founder or indie hacker, you might be lured by the promises of AI coding tools that claim to simpli

Oct 13, 20264 min read
Ai Coding Tools

5 Common Mistakes Developers Make When Using AI Coding Tools in 2026

5 Common Mistakes Developers Make When Using AI Coding Tools in 2026 As AI coding tools have become an integral part of a developer's toolkit in 2026, many are still stumbling over

Oct 12, 20264 min read
Ai Coding Tools

5 Myths About AI Coding Tools: What Every Developer Should Know in 2026

5 Myths About AI Coding Tools: What Every Developer Should Know in 2026 As we dive into 2026, the landscape of AI coding tools has evolved significantly, yet many developers still

Oct 11, 20263 min read
Ai Coding Tools

Why AI Coding Assistants Are Overrated for Beginners in 2026

Why AI Coding Assistants Are Overrated for Beginners in 2026 As a solo founder or indie hacker, it’s tempting to think that AI coding assistants are the silver bullet to jumpstart

Oct 10, 20263 min read