How to Make Your First Open Source Contribution

author
By Sneha Patel

5/22/2026

6

Contributing to open source software is the best way to build your resume and improve coding skills. Follow this step-by-step guide to make your first GitHub pull request.

image

Open Source Software (OSS) powers the modern internet. Frameworks like React, operating systems like Linux, and tools like VS Code are all maintained by communities of developers worldwide.

For B.Tech students, contributing to open source is arguably the single most impactful way to boost a resume. It proves to recruiters that you can read complex codebases, collaborate with senior engineers, and use Git version control effectively.

However, making that first contribution can be intimidating. The codebase is huge, the documentation is dense, and the fear of making a mistake is high. In this guide, we break down the exact steps to successfully make your first open-source contribution.


Table of Contents

  1. Why Contribute to Open Source?
  2. Step 1: Finding Beginner-Friendly Projects
  3. Step 2: Understanding the Repository Structure
  4. Step 3: The Fork and Clone Workflow
  5. Step 4: Writing Code and Submitting a Pull Request
  6. Frequently Asked Questions (FAQs)
  7. Conclusion

1. Why Contribute to Open Source?

Before diving into the "how," let's establish the "why."

  • Real-World Experience: You learn how production-grade software is structured, which is impossible to learn from isolated college projects.
  • Networking: You interact with senior engineers who review your code. These connections often lead to job referrals.
  • Resume Proof: A link to a merged Pull Request (PR) on a major repository is undeniable proof of your coding abilities.

2. Step 1: Finding Beginner-Friendly Projects

Do not try to fix a core C++ memory leak in the Linux kernel on your first day. Start small.

Look for "Good First Issue" Labels

Maintainers often tag easy bugs or documentation fixes with specific labels to attract beginners.

  • Go to GitHub and search for label:"good first issue" or label:"first-timers-only".
  • Use aggregator websites like Up For Grabs (up-for-grabs.net) or Good First Issue (goodfirstissue.dev) to find beginner-friendly tickets in popular languages like JavaScript or Python.

What to Look For:

For your very first PR, look for typo fixes in the README.md, broken link repairs, or simple CSS alignment issues. The goal is to learn the workflow, not to write complex logic.


3. Step 2: Understanding the Repository Structure

Once you find an issue you want to tackle, do not immediately start coding. First, understand the rules of the repository.

  1. Read CONTRIBUTING.md: This file contains the exact steps required to set up the project locally, run the tests, and format your code. If you ignore this, your PR will likely be rejected.
  2. Read the Issue Carefully: Ensure no one else is currently working on it. If it is free, leave a comment saying: "Hi, I would like to work on this issue. Could you assign it to me?"

4. Step 3: The Fork and Clone Workflow

You cannot push code directly to someone else's repository. You must create a copy of it.

  1. Fork the Repository: Click the "Fork" button in the top-right corner of the GitHub page. This creates a copy of the repository under your own GitHub account.
  2. Clone Your Fork: Download the code to your local machine. git clone https://github.com/YOUR-USERNAME/repository-name.git
  3. Set Up Upstream Remote: Link your local repo to the original project so you can pull the latest changes. git remote add upstream https://github.com/ORIGINAL-OWNER/repository-name.git
  4. Create a Branch: Create a new branch for your specific fix. git checkout -b fix/header-typo

5. Step 4: Writing Code and Submitting a Pull Request

Once your branch is ready, it is time to write high-quality code that maintainers will want to merge. Remember, open-source maintainers are busy volunteers; making their job easier increases the chance of your pull request getting accepted.

A. The Coding and Testing Phase

  • Isolate Your Changes: Keep your changes limited to the issue you are solving. Do not refactor unrelated files or fix formatting in unrelated areas. This makes code review difficult.
  • Run the Local Environment: Start the development server (e.g., npm run dev) and thoroughly test your changes. Ensure the bug is fixed and no other features are broken.
  • Format and Lint: Most repositories have automated linters and code formatters (like Prettier or ESLint). Run the format command (e.g., npm run format or npm run lint) before committing. Mismatched code styles are one of the most common reasons PRs fail automated checks.

B. Crafting a Perfect Commit Message (Conventional Commits)

Professional projects follow commit message guidelines known as "Conventional Commits". Instead of generic messages like "fixed bug" or "done", use a structured format: type(scope): description

  • feat: Introducing a new feature (e.g., feat(auth): add google login button)
  • fix: Fixing a bug (e.g., fix(sidebar): resolve overflow issue on mobile)
  • docs: Changes to documentation (e.g., docs(readme): add installation steps)
  • style: Formatting changes, missing semicolons, etc. (e.g., style(header): fix indentation)

Example command:

git add .
git commit -m "fix(nav): resolve broken link in resources dropdown"

C. Creating and Submitting the Pull Request

  1. Push to Your Fork: Push your branch to your own GitHub repository:
    git push origin fix/header-typo
    
  2. Initialize the PR: Open the original repository page on GitHub. GitHub will automatically detect your newly pushed branch and show a banner with a green "Compare & pull request" button. Click it.
  3. Fill Out the PR Description: If the repository has a PR template, fill it out completely. Explain:
    • What was changed.
    • Why the change was made.
    • How you tested it (include screenshots for UI changes).
    • Link the issue by typing Closes #12 (replacing 12 with the actual issue number). This automatically closes the issue once your PR is merged.
  4. Pass Automated Checks (CI/CD): Once submitted, automated platforms (like GitHub Actions) will run unit tests and style checks. If you see a red cross, click "Details", find the error, fix it locally, and push the fix to your branch. The PR will update automatically!

6. Frequently Asked Questions (FAQs)

Q1. What if the maintainer asks me to make changes to my PR?

This is completely normal and expected! Code reviews are part of the process of open-source collaboration. Simply make the requested changes in your local branch, test them, stage and commit them, and then push them to your branch on GitHub. The pull request page will update automatically with your new commits. There is no need to open a new pull request!

Q2. Does changing documentation count as an open source contribution?

Yes, absolutely. In fact, many major open-source projects actively struggle to keep their documentation up to date as features change. Contributions that fix typos, clarify complex setup instructions, write tutorials, or translate the guides into different languages are highly valued by the community. They are a great way to build your confidence and learn the repository layout before writing actual source code.

Q3. Can I participate in Hacktoberfest as a beginner?

Yes! Hacktoberfest (held every October) is designed specifically to encourage beginners to make open source contributions. It is the perfect time to start your OSS journey. Thousands of repositories prepare beginner-friendly issues tagged with hacktoberfest to help new developers get comfortable.

Q4. What if my PR gets ignored for a long time?

Be patient. Open-source maintainers are doing this work in their free time alongside their primary jobs. If a week or two passes without any activity or feedback, it is perfectly acceptable to polite ping them. Write a short, respectful comment on the pull request like: "Hi @username, just checking in to see if you have any feedback or if there is anything else I can improve here. Thank you!" Avoid pinging them repeatedly or across multiple channels, which can be seen as spammy.

Q5. What is the difference between merging, rebasing, and squashing commits?

When a pull request is merged, there are three common methods maintainers might use:

  • Create a merge commit: All commits from your feature branch are added to the main branch along with a special "merge commit" that ties the branches together.
  • Rebase and merge: Your commits are individual units applied on top of the main branch's commits. This keeps a clean, linear history.
  • Squash and merge: All of your small, incremental commits (like "fix typo", "update css", "oops fixed typo again") are consolidated (squashed) into a single, clean commit. This keeps the commit history of the main branch extremely readable and professional. Do not worry about having too many small commits on your branch; squashing will clean it up!

7. Conclusion

Making your first open source contribution might seem daunting, but the open source community is generally very welcoming to beginners. By following the Fork-Clone-PR workflow and starting with "good first issues," you can easily secure your first merged pull request. Take the leap, write some code, and become part of the global developer community!

Suggested Images:

  • Featured Image: A graphic showing the Open Source contribution workflow: Fork, Clone, Push, Pull Request (Prompt: Open source contribution workflow diagram, GitHub fork and pull request icons, modern tech style).
  • Inline Image: A screenshot showing where to find the "Good First Issue" labels on GitHub issues.

Alt Texts:

  • Featured Image: "Open source contribution workflow from Fork to Pull Request"
  • Inline Image: "GitHub good first issue label search interface"

Internal Linking Suggestions:

Popular Tags :

Share this post :

Comments (0)

Leave a Comment

Loading comments...