Ai Coding Tools

How to Use GitHub Copilot to Write Your First App in Under 2 Hours

By BTW Team3 min read

How to Use GitHub Copilot to Write Your First App in Under 2 Hours

If you’ve ever stared at a blank screen, wondering how to turn your app idea into reality, you’re not alone. As indie hackers and solo founders, we often face the daunting task of coding from scratch. But what if I told you that you could create your first app in under two hours with the help of GitHub Copilot? In this guide, I’ll walk you through the process, share my experiences, and highlight the limitations.

Prerequisites: What You Need Before You Start

Before diving in, ensure you have the following:

  1. A GitHub Account: You’ll need this to access GitHub Copilot.
  2. Visual Studio Code (VS Code): Download and install VS Code if you haven’t already.
  3. GitHub Copilot Subscription: It costs $10/month or $100/year. There’s a free trial available, so you can start without commitment.
  4. Basic Understanding of JavaScript: Familiarity with JavaScript will help you make the most of Copilot's suggestions.

Step 1: Set Up Your Environment (15 Minutes)

  1. Install VS Code: If you haven’t already, download and install Visual Studio Code.
  2. Install GitHub Copilot: Go to the Extensions tab in VS Code and search for "GitHub Copilot." Click "Install."
  3. Create a New Project: Open a new folder in VS Code. Create a new file named app.js.

Step 2: Write Your First Function (20 Minutes)

Now, let’s write a simple function. For example, if you're building a to-do list app, start with a function to add a task.

  1. In app.js, type function addTask(task) { and hit Enter. Copilot will suggest the rest of the function.
  2. Accept the suggestion or modify it as needed.

Expected output:

function addTask(task) {
    // Code to add task
}

Step 3: Expand Your App (30 Minutes)

Continue building your app by adding more functionalities like displaying tasks and removing tasks. Here’s how:

  1. Ask Copilot for a function to display tasks by typing function displayTasks() { and hitting Enter.
  2. Review and adjust the generated code as necessary.

Expected output:

function displayTasks() {
    // Code to display tasks
}

Step 4: Test Your App (30 Minutes)

Once you have your basic functions, it’s time to test them.

  1. Create a simple HTML file to interact with your JavaScript functions.
  2. Open the browser and check if the app works as expected.

Expected output: Your app should be able to add and display tasks without errors.

Troubleshooting: What Could Go Wrong

  1. Syntax Errors: If you see red underlines in your code, hover over them to see suggestions.
  2. Logic Errors: Test each function individually to ensure they work as intended.
  3. Copilot Suggestions: Sometimes, Copilot may suggest code that doesn’t fit your use case. Don’t hesitate to modify it.

What’s Next: Building On Your Foundation

Congratulations! You’ve built a simple app in under two hours. From here, consider the following steps to enhance your app:

  • Add CSS for Styling: Use frameworks like Tailwind CSS or Bootstrap.
  • Deploy Your App: Try platforms like Vercel or Netlify for free hosting.
  • Iterate Based on User Feedback: Share your app with friends or fellow builders for feedback.

Conclusion: Start Here

Using GitHub Copilot can significantly speed up your development process, especially if you’re just starting. While it won’t write your entire app for you, it can provide valuable suggestions and save you time. If you’re ready to jump in, set up your environment, and start coding.

What We Actually Use

In our experience, we rely on GitHub Copilot for initial code generation but always double-check and refine the output. It’s a powerful assistant, but it’s not foolproof.

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