GitHub Repository Setup and Cursor Integration: A Step-by-Step Guide

What You'll Learn in This Lesson
In the previous lesson, you learned about Git and GitHub concepts.
This time, we'll register a project on GitHub for real.
By the end of today's lesson,
Create a GitHub repository
Connect Cursor to your project
Make your first Commit
Upload to GitHub (Push)
you'll have completed all these steps.
From now on, all projects will be managed around this repository.
Why Connect to GitHub Now?
Many beginners wait until their project is mostly finished before uploading it to GitHub.
However, in actual development, it's common to connect to GitHub from the very beginning of a project.
The reason is simple:
From day one of starting your project,
You can back up your work
Manage versions effectively
Prepare for collaboration
Utilize AI tools
all become possible.
Create a GitHub Repository
First, log in to GitHub.
After logging in, click the New Repository button at the top right of the screen.
Name your repository something easy to recognize for your project.
This lesson will use:
dating-app
You can choose between a public or private repository.
For learning purposes, public is fine, but for actual services, we recommend using a private repository.
We'll Create README Later
GitHub allows you to automatically create a README file when creating a repository.
However, this lesson will skip that option.
The reason is we plan to make the first Commit directly from the Cursor project.
Creating an empty repository is cleaner for this process.
Open Your Cursor Project
Launch Cursor.
Open the dating-app project you created in the previous lesson.
Currently, your project is just a regular folder, not a Git repository.
Now we'll convert it into a Git project.
Initialize Git Repository
Open the terminal and enter this command:
git init
This command converts your current folder into a Git project.
If successful, a hidden .git folder will be created.
This folder stores all change history for your project.
Check Git Status
Enter this command:
git status
This shows the current state of your project.
Initially, most files will be marked as Untracked files, meaning Git isn't managing them yet.
Configure Git to Track Files
To register all files with Git, enter this command:
git add .
The . here means all files in the current folder.
Now Git will start tracking all files.
Create Your First Commit
Let's create your first project checkpoint.
Enter this command:
git commit -m "Initial project setup"
The Commit message is a brief description of what you're doing.
For the first Commit, common phrases include:
Initial project
First commit
etc.
Connect GitHub Repository to Your Project
Now we'll connect your GitHub repository with the current project.
After creating a GitHub repository, you'll see an address like this:
https://github.com/username/dating-app.git
Or if using SSH:
git@github.com:username/dating-app.git
This connects your project with GitHub, allowing you to freely exchange data between them.
What Is Remote?
A GitHub-connected repository is called a Remote Repository.
In contrast, the project on your computer is a Local Repository.
So you can think of it this way:
Local → Your computer
Remote → GitHub
Push to GitHub (Upload)
Now we'll upload your first project to GitHub.
Push sends your current work to GitHub.
After uploading, you can see the project files on the GitHub website as well.
From now on, your project is safely backed up.
Verify After Push
Refresh GitHub and you'll see:
The project folder
A file list
Commit history
You can now retrieve your project from anywhere, even if your computer fails.
How You'll Work From Now On
From now on, whenever you add new features, follow this sequence:
Write code
Test
Commit
Push
Repeating this process will make project management much easier.
How to Write Good Commit Messages
A good commit message helps understand your project later.
For example:
Good examples
Add login page
Create profile component
Fix login bug
Update user interface
Bad examples
Modified
Changed
Tried
aaa
Write commit messages that clearly show what you did.
Should You Use GitHub Desktop?
Beginners often use GitHub Desktop.
However, this lesson focuses on command-line operations because it's more flexible with Cursor AI and GitHub MCP, which are commonly used in professional settings.
It might feel challenging at first, but you'll get comfortable after a few repetitions.
GitHub in the AI Era
In the past, developers wrote commit messages themselves.
Now you can ask Cursor AI:
Analyze the changes and write a commit message for me.
You can also connect GitHub MCP to have it analyze your project, understand changes, and suggest appropriate commit messages.
We'll use these features going forward as well.
Next Lesson Preview
In the next lesson, we'll dive deeper into what MCP (Model Context Protocol) is.
Understanding how AI connects with GitHub, Supabase, and Vercel to perform actual work will completely change your development approach.
Wrap-Up
In this lesson, you practiced creating a GitHub repository and connecting it with your Cursor project.
Your project is now managed by Git and safely stored on GitHub.
Going forward, whenever you add new features, you'll repeat Commit and Push to manage your project systematically.
The next lesson will cover MCP, the core technology of AI development, showing how Cursor AI evolves from a simple chatbot into an actual development partner.
FAQ
Why should I connect GitHub from the start of a project?
Connecting early allows for backup, version management, collaboration preparation, and AI tool integration right from day one.
What's the difference between Local and Remote repositories?
Local refers to your computer's files while Remote means the GitHub repository where your code is stored online.
Korean Source
This article is an English localization of a Korean-language report from BlogScore. Original: [바이브코딩 강좌] 7강. GitHub 저장소 생성과 Cursor 연결하기