Skip to main content

GitHub file size limits — and how to fit under them

GitHub caps uploads in a few different places: 25 MB in the browser, 10 MB for images and videos in issues, 100 MB per file over git. Here's every limit, why you hit it, and how to compress a file locally to get under it.

Every GitHub upload limit

Image or GIF in an issue, PR, or comment 10 MB
Video in an issue/PR (free account) 10 MB
Video in an issue/PR (paid account) 100 MB
Any other file in an issue/PR/comment 25 MB
File uploaded to a repo in the browser 25 MB
File pushed with git (warning) 50 MB
File pushed with git (hard block) 100 MB
Asset attached to a Release 2 GB

Source: GitHub Docs — attaching files and about large files on GitHub. Limits as of June 2026.

Get under the limit — without uploading your file anywhere

Most "file too big" errors on GitHub are media that's just over the line. Compress it locally in FileHop and re-attach — nothing leaves your machine, so it's safe for assets headed into a private repo.

Genuinely over 100 MB? Compression is the wrong fix for a large dataset or binary. Track it with Git LFS, or attach it to a GitHub Release (up to 2 GB per file). Compress when it's media a little over the limit; switch to LFS/Releases when the file is fundamentally large.

Frequently asked questions

What is the maximum file size on GitHub?

It depends on where you're uploading. In the browser you can upload files up to 25 MB to a repository. Over git, files larger than 50 MB trigger a warning and files over 100 MB are blocked outright. In issues, PRs, and comments, images and GIFs are limited to 10 MB, videos to 10 MB on free accounts (100 MB on paid), and all other files to 25 MB. Release assets can be up to 2 GB.

Why does GitHub say my image is too big when it's only ~12 MB?

Images and GIFs attached to issues, pull requests, and comments are limited to 10 MB. A couple of full-resolution screenshots or a short screen recording saved as a GIF can easily exceed that. Compressing or resizing the image to under 10 MB fixes it.

How do I compress a screenshot to upload to a GitHub issue?

Open the image in FileHop and use Compress (or resize it to a smaller resolution), then export. It runs entirely on your computer — nothing is uploaded to a third-party site — and you can dial in the quality so the screenshot stays readable while dropping under 10 MB.

My video won't attach to an issue — how do I get it under 10 MB?

Re-encode it at a lower bitrate and/or resolution. For a bug repro, 720p (or even 480p) at a modest bitrate is usually plenty and gets most short clips well under 10 MB. FileHop compresses video locally so you don't upload an unreleased product clip to a random online tool.

What if my file is genuinely over 100 MB?

Compression won't save a 500 MB dataset or a large binary — that's the wrong tool. For large files that belong in a repo, use Git LFS (Large File Storage). For distributing big build artifacts or installers, attach them to a GitHub Release, which allows up to 2 GB per file. Compress when the file is media that's a bit over the limit; switch to LFS/Releases when it's fundamentally large.

Is it safe to use an online compressor for a file going into a private repo?

Be careful. Uploading an unreleased screenshot, internal log, or proprietary asset to a free online compressor means handing that file to a third party. A local tool that compresses on your own machine avoids the exposure entirely — which matters more for work going into a private repository.

Does compressing reduce quality?

For images and video it's a trade-off you control: lower the quality/bitrate and the file shrinks. For getting under an upload limit, the small quality drop is usually invisible at normal viewing sizes. PDFs often compress significantly with little to no visible change, since most of the size is over-large embedded images.

Is FileHop free, and does it work offline?

Yes — FileHop is free for Mac and Windows and compresses images, video, PDFs, and audio entirely offline. Nothing is uploaded, so it's safe for files headed into private repos.