Ai Coding Tools

How to Use GitHub Copilot to Build a Simple App in 2 Hours

By BTW Team4 min read

How to Use GitHub Copilot to Build a Simple App in 2026

If you're a solo founder or indie hacker, you know that building an app can feel like a daunting task. With so many tools out there, it's easy to get lost in the noise. But what if I told you that you could leverage AI to speed up the development process? Enter GitHub Copilot, a tool that can help you write code faster and more efficiently. In this guide, I’ll show you how to build a simple app in just 2 hours using GitHub Copilot.

Time Estimate: 2 Hours

This entire process should take about 2 hours if you follow along closely and have the prerequisites set up.

Prerequisites

Before we dive in, make sure you have the following:

  • A GitHub account (Free tier available)
  • Visual Studio Code (Free)
  • The GitHub Copilot extension for Visual Studio Code (Free tier + $10/mo for individual users)
  • Basic understanding of JavaScript or Python (we'll use JavaScript for this tutorial)

Step 1: Set Up Your Development Environment

  1. Install Visual Studio Code: Download and install Visual Studio Code from here.

  2. Install GitHub Copilot: In Visual Studio Code, go to Extensions (Ctrl + Shift + X) and search for "GitHub Copilot". Click "Install".

  3. Sign in to GitHub: After installation, sign in to your GitHub account when prompted.

Expected Output: You should see a Copilot icon in the bottom right corner of your VS Code window.

Step 2: Create a New Project

  1. Open a New Folder: Create a new folder for your project and open it in Visual Studio Code.

  2. Create an index.js File: In your project folder, create a new file named index.js.

  3. Initialize a Basic HTML File: Create an index.html file with a simple HTML structure.

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Simple App</title>
</head>
<body>
    <h1>Welcome to My Simple App</h1>
    <script src="index.js"></script>
</body>
</html>

Expected Output: Open index.html in your browser, and you should see "Welcome to My Simple App".

Step 3: Use GitHub Copilot to Write Code

Now comes the fun part! Let’s start building the functionality of your app. For this example, we will create a simple to-do list.

  1. Start Coding: In the index.js file, type a comment describing the functionality you want, like this:
// Create a function to add a to-do item
  1. Let Copilot Suggest Code: GitHub Copilot will automatically suggest code. You can accept the suggestion by pressing Tab or keep typing for more options.

  2. Implement the Functionality: Repeat this process for the following functions:

    • Create a function to display the to-do list
    • Create a function to remove a to-do item
    • Add event listeners for user interaction

Expected Output: You should have a functioning to-do list that allows users to add and remove items.

Troubleshooting: What Could Go Wrong

  1. No Suggestions from Copilot: Make sure you are connected to the internet and logged into GitHub within Visual Studio Code.

  2. Syntax Errors: If Copilot suggests code that doesn’t work, you can always modify it. Remember, it’s an assistant, not a replacement for your coding skills.

  3. App Not Working: Double-check your HTML file to ensure the JavaScript file is linked correctly.

What's Next

Once you’ve built your simple app, consider deploying it using platforms like Vercel or Netlify. Both offer free tiers that are perfect for indie projects. You can also explore adding more features, like user authentication or a database to store your to-do items.

Conclusion: Start Here

Using GitHub Copilot can significantly reduce the time it takes to build a simple app. Get started today by setting up your environment and following the steps outlined above. With just a couple of hours, you can have a functional to-do list app and a better understanding of how to leverage AI in your coding workflow.

What We Actually Use

  • Visual Studio Code: Free
  • GitHub Copilot: $10/mo for individual users
  • Vercel/Netlify: Free tier for deployment

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

How to Build an MVP with AI Coding Tools in 2 Weeks

How to Build an MVP with AI Coding Tools in 2 Weeks Building a minimum viable product (MVP) in two weeks sounds nearly impossible, right? It’s a common pain point for indie hackers

Apr 5, 20264 min read
Ai Coding Tools

The $100 AI Coding Toolkit: Essential Tools for Aspiring Developers

The $100 AI Coding Toolkit: Essential Tools for Aspiring Developers As an aspiring developer in 2026, you might feel overwhelmed by the sheer number of tools available to help you

Apr 5, 20266 min read
Ai Coding Tools

Why GitHub Copilot is Overrated for New Devs

Why GitHub Copilot is Overrated for New Devs As a new developer, diving into coding can feel overwhelming. You want to write clean, efficient code, but there’s so much to learn. En

Apr 5, 20264 min read
Ai Coding Tools

How to Use Cursor to Automate Your Coding Workflow in 30 Minutes

How to Use Cursor to Automate Your Coding Workflow in 30 Minutes As a solo founder or indie hacker, you know that time is your most precious resource. But when it comes to coding,

Apr 5, 20264 min read
Ai Coding Tools

Struggling with AI Code Suggestions? Here Are 5 Common Mistakes to Avoid

Struggling with AI Code Suggestions? Here Are 5 Common Mistakes to Avoid As developers, we often turn to AI coding tools to boost our productivity and streamline our workflows. But

Apr 5, 20264 min read
Ai Coding Tools

AI Coding Tools Showdown: Cursor vs. Codeium – Which One Saves You More Time?

AI Coding Tools Showdown: Cursor vs. Codeium – Which One Saves You More Time? As a solo founder or indie hacker, time is your most precious resource. You’re probably juggling multi

Apr 5, 20263 min read