Step 1: Sign in to your GitHub account
To start, open your web browser and navigate to GitHub’s homepage at https://github.com.
- Enter your Username or email address and Password, then click Sign in.
- If you don’t have an account yet, click Sign up and follow the on-screen prompts to create one.
Step 2: Create a new repository or open an existing one
After signing in, you have two options:
- Create a new repository:
- Click the + icon in the top-right corner and choose New repository.
- Fill in the Repository name (e.g.,
my-first-repo
), add an optional description, and choose Public or Private.
- Click Create repository.
- Open an existing repository:
- From your profile or the Your repositories dropdown, select the repository you want to upload files to.
Step 3: Access the Upload Files interface
Once you’re inside your repository:
- Ensure you’re on the Code tab.
- Click the Add file button, then select Upload files.
- You’ll see an area labeled Drag files here to add them to your repository.
Step 4: Drag and drop your files or folders
Now perform the actual drag-and-drop:
- Open your file manager (Finder on macOS, Explorer on Windows).
- Select one or multiple files and/or folders from your local machine.
- Drag them over to the browser window and drop them into the upload area.
- You will see each file listed with its size. GitHub enforces a maximum file size of 25 MB per file—larger assets require Git LFS or another storage solution.
Step 5: Review and commit your changes
After dropping your files:
- Scroll down to the Commit changes section.
- Enter a descriptive commit message in the first field, for example: “Add initial project files”.
- Choose whether to commit directly to the main branch or create a new branch for a pull request.
- Click the Commit changes button to finalize the upload.
Step 6: Verify that your files are in the repository
Upon committing:
- The page will refresh and display your newly uploaded files in the repository’s file list.
- Click on any file name to view its contents directly on GitHub.
- Use the repository’s history tab to see your recent commit and message.