Ai Coding Tools

How to Use GitHub Copilot to Write Your First Lines of Code in 30 Minutes

By BTW Team3 min read

Comparing tools? See the AI tools tested on the show.

In short

A step-by-step guide on using GitHub Copilot effectively for writing your initial code, perfect for newbies looking to learn quickly.

If you've ever found yourself staring at a blank code editor, unsure of where to begin, you're not alone. Many beginners struggle with the initial hurdle of writing code. What if I told you that you could write your first lines of code in just 30 minutes using GitHub Copilot? In 2026, this AI-powered tool is more accessible and powerful than ever, making it a great companion for budding developers. Here's how you can get started.

Prerequisites: What You Need Before Starting

Before diving into GitHub Copilot, make sure you have the following:

  1. GitHub Account: Create one if you don’t have it already. It's free.
  2. Visual Studio Code: Download and install it. This is where you'll write your code.
  3. GitHub Copilot Subscription: As of August 2026, the pricing is $10/month for individuals after a 30-day free trial.
  4. Basic Understanding of Programming Concepts: Familiarity with variables, functions, and syntax will help, but you can still follow along if you're a complete beginner.

Step 1: Installing GitHub Copilot

  1. Open Visual Studio Code.
  2. Go to the Extensions view by clicking on the Extensions icon in the Activity Bar.
  3. Search for "GitHub Copilot" and click on "Install."
  4. Once installed, sign in with your GitHub account.

Expected Output: You should see a Copilot icon in the status bar, indicating it's ready to assist you.

Step 2: Creating Your First Project

  1. Create a new folder on your computer for your project.
  2. Open that folder in Visual Studio Code.
  3. Create a new file called hello.js (or hello.py, depending on your preferred language).

Expected Output:

You'll have a new file open and ready for coding.

Step 3: Writing Your First Lines of Code with GitHub Copilot

  1. Start typing a simple comment like // This program prints Hello, World! (for JavaScript) or # This program prints Hello, World! (for Python).
  2. After typing the comment, hit Enter, and GitHub Copilot will suggest code. Accept the suggestion by pressing Tab.

Expected Output:

You should see a line of code that prints "Hello, World!" to the console.

Step 4: Running Your Code

  1. For JavaScript, open the terminal in VS Code and run node hello.js. For Python, run python hello.py.
  2. You should see "Hello, World!" printed in the terminal.

Troubleshooting:

  • If you encounter errors, double-check that you have the correct runtime installed (Node.js for JavaScript, Python for Python).
  • Ensure your file has the correct extension.

What's Next: Building on Your Knowledge

Now that you've successfully written and run your first program, consider exploring more complex projects. Here are some ideas:

  • Build a Simple Calculator: Use Copilot to help you write functions for addition, subtraction, multiplication, and division.
  • Create a To-Do List App: Implement basic CRUD operations with Copilot's suggestions.
  • Learn GitHub Basics: If you haven't already, familiarize yourself with Git and GitHub for version control.

Conclusion: Start Here

Using GitHub Copilot can significantly ease the learning curve of programming. It's not just a fancy autocomplete; it helps you understand coding concepts by suggesting useful code snippets based on your input. Follow the steps above to get your first lines of code up and running in 30 minutes.

If you're looking for a practical way to get into coding, GitHub Copilot is a solid choice.

Watch real AI builds every week

Built This Week is a weekly podcast where Jordan Metzner and Sam Nadler build something real with AI every episode, test new AI tools and talk with founders who build with AI.

See the tools

Watch real AI builds every week

Built This Week is a weekly podcast where Jordan Metzner and Sam Nadler build something real with AI every episode, test new AI tools and talk with founders who build with AI.

See the tools
Ai Coding Tools

3 AI Coding Tools That Are Overrated (and Why You Should Avoid Them)

3 AI Coding Tools That Are Overrated (and Why You Should Avoid Them) In the everevolving landscape of AI coding tools, it's easy to get swept up in the hype. As indie hackers and s

Nov 30, 20263 min read
Ai Coding Tools

5 Ways AI Coding Tools Can Accelerate Your MVP Development in 2026

5 Ways AI Coding Tools Can Accelerate Your MVP Development in 2026 In 2026, the landscape for indie hackers and solo founders has evolved significantly, especially with the advent

Nov 26, 20264 min read
Ai Coding Tools

5 AI Coding Tools That Make Legacy Code Feel Brand New in 2026

5 AI Coding Tools That Make Legacy Code Feel Brand New in 2026 If you’re a developer stuck maintaining legacy code, you know the frustration. It’s like navigating a maze blindfolde

Nov 23, 20264 min read
Ai Coding Tools

10 AI Coding Tools That Will Save You Hours of Debugging in 2026

10 AI Coding Tools That Will Save You Hours of Debugging in 2026 Debugging can feel like a neverending cycle of frustration. Whether you're a solo founder or an indie hacker, spend

Nov 18, 20265 min read
Ai Coding Tools

10 Common Mistakes When Using AI Coding Tools for MVP Development

10 Common Mistakes When Using AI Coding Tools for MVP Development As a founder in 2026, you’re likely aware that AI coding tools can significantly speed up the MVP development proc

Nov 16, 20264 min read
Ai Coding Tools

5 AI Coding Myths Every Beginner Developer Should Ditch in 2026

5 AI Coding Myths Every Beginner Developer Should Ditch in 2026 As a beginner developer, you’ve probably come across a ton of buzz surrounding AI coding tools. But with all the hyp

Nov 12, 20263 min read