GitHub Raw Link Generator: Convert Blob & Gist URLs to Direct CDNs
Convert GitHub file and Gist URLs into direct raw.githubusercontent.com links, production jsDelivr & Statically CDN URLs with valid CSS/JS MIME headers, live HTTP check, and embed snippets.
text/plain with nosniff. Great for cURL, raw downloads, and configs; browsers block CSS/JS loaded from here.
text/css and application/javascript headers for live sites.
<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/twbs/bootstrap@main/dist/css/bootstrap.min.css">
How to Convert GitHub Links in 3 Steps
Copy GitHub File or Gist URL
Copy any public repository URL (/blob/, /raw/refs/heads/, Gist, or a raw.githubusercontent.com link with line anchors).
Paste in Single or Batch Mode
The parser automatically strips hash anchors (#L10), query flags (?plain=1), and refs/heads/ prefixes cleanly.
Verify & Copy Raw, CDN, or Snippet
Run Check Status to confirm live 200 OK MIME headers, or copy HTML, ES Module, Markdown, cURL, or Fetch snippets.
The Complete Guide to GitHub Raw Links, MIME Types & CDNs
raw.githubusercontent.com files with text/plain and nosniff headers, so browsers block CSS and JS loaded directly from raw URLs. Converting them to jsDelivr or Statically CDN links restores proper text/css and application/javascript MIME types.
Why raw.githubusercontent.com Blocks CSS and JavaScript
Modern browsers reject stylesheets and scripts loaded directly from raw.githubusercontent.com because GitHub intentionally sends two headers:
- Content-Type: text/plain; charset=utf-8: Every raw file is tagged as plain text regardless of its
.css,.js, or.mjsextension. - X-Content-Type-Options: nosniff: Forces browsers to strictly obey the
text/plainheader instead of guessing the file type—blocking script execution and CSS parsing.
How jsDelivr & Statically Fix MIME Types
Public open-source CDNs like jsDelivr and Statically fetch files from public GitHub repositories, attach valid MIME headers (text/css, application/javascript, image/svg+xml), and serve them globally over Anycast edge servers with Brotli/Gzip compression.
Branch Links vs. Immutable Commit SHAs & Tags
- Branch Link (
@main): Tracks your latest commits, though edge CDN caches may hold branch files for up to 24 hours unless purged viapurge.jsdelivr.net. - Tag or Commit SHA (
@v5.3.0or@4a1b2c3): Immutable and permanently cached—best practice for production websites to avoid unexpected breaking changes.
GitHub Link Formats & CDN Comparison Matrix
| Link Format | MIME Type Handling | Caching / Speed | Best Used For |
|---|---|---|---|
| GitHub Web View | HTML Webpage | Origin page | Code reading, PRs, issue review |
| Raw GitHub | Enforced text/plain | Origin (short cache) | cURL downloads, JSON/YAML configs, raw text |
| jsDelivr CDN | Valid MIME (CSS/JS/SVG) | Global Anycast CDN | Live HTML <link> & <script> embeds |
| Statically CDN | Valid MIME | Multi-CDN edge network | Images, fonts, and fallback asset delivery |
| GitHub Gist Raw | text/plain | Origin cache | Lightweight snippet sharing & CLI scripts |
Frequently Asked Questions
Explore More Tools & Useful Platforms
Check out our other free developer, media, and productivity tools across the 1io network:
Scale image/video dimensions proportionally, find GCD ratios, and generate CSS snippets.
Open Aspect Ratio Calculator →Strip ChatGPT fluff, Markdown syntax, citations, and invisible Unicode characters instantly.
Open AI Text Cleaner →Verify camera resolution, live FPS, megapixels, snapshots, and microphone levels in 1 click.
Open Webcam Test →Read tutorials on 1io.site or watch tech walkthroughs on videos.1io.site.
Visit 1io.site →