Paste a link, get one file

Turn a GitHub repo into one text or .txt file.

Paste a public repository URL and press Fetch. Lock files, dependencies and build output stay out. The rest comes back as one file with the file tree at the top. Its token count tells you whether it fits your model before you paste it.

  • Fetched by your browser, straight from GitHub
  • Token count shown before you paste
  • No sign-up, files not uploaded to us

Paste a public link

Try
or

Drop a cloned folder

For a private repository, or one you have changed.

How many tokens is a GitHub repo?

We bundled 60 public repositories whole with this engine in September 2026. The median came to 236,218 tokens, 23 of 60 fit a 128K window, and the largest reached 5,535,907. There is no typical size to plan around, which is why the count comes before the paste.

Method and every repository: how many tokens a codebase is.

  • 23 of 60 fit 128K (38%)
  • 26 of 60 fit 200K (43%)
  • 43 of 60 fit 1M (72%)
5,722 tokens5,535,907 tokens
60 public repositories as one file each, median 236,218 tokens

What stays out of the file.

On our fresh clones the defaults removed about a fifth of the tokens, about a third of it tests. Anything here can go back in under Adjust what's included.

Left outFor example
Version control.git
Dependencies and vendored codenode_modules, vendor, third_party
Lock filespackage-lock.json, Cargo.lock, go.sum
Build outputdist, build, target
Test files named as testsapi.test.ts, handler_test.go

Markdown, XML or plain text.

The same single file comes in three styles, switched under the preview. Across five real codebases the switch changed the total by at most about 1% of tokens, so use the one your prompt already uses.

The measurement: XML vs Markdown for LLM context.

Every file under its path

Whatever the style, the file opens with the repository's tree. Every file sits under its own path, so the model can tell src/index.ts from test/index.ts.

GitHub repo to text in four steps.

  1. 1

    Paste the repository URL

    The whole repository, a branch with /tree/branch, or one folder with /tree/branch/path.

  2. 2

    Press Fetch

    Your browser downloads the files straight from GitHub, with no server in between.

  3. 3

    Leave out what you do not need

    Open Adjust what's included: every file and folder shows its share of the text, and the token count updates as you click rows out.

  4. 4

    Copy or download the one file

    Paste it into ChatGPT, Claude or Gemini, or add it to a project, with the count already known.

Common questions.

How do I convert a GitHub repo to a text file?
Paste the repository URL at the top of this page and press Fetch. Your browser downloads the files straight from GitHub. Lock files, dependencies, build output and test files are left out by default. You get back one text file with the file tree at the top and every file under its path. Copy it or download it.
Can I download the repo as a .txt file?
Yes. Set Format to Plain under the preview and Download saves a .txt file. XML, the default, saves as .xml and Markdown as .md. All three hold the same file tree and the same files.
How many tokens is a GitHub repository?
It varies more than any average suggests. We bundled 60 public repositories in 10 languages on 2026-09-11. The median came to 236,218 tokens, 23 of 60 fit a 128K context window, and the largest reached 5,535,907. FileConcat counts yours before you paste it.
Can I convert a private repository?
Not by link. The import reads public repositories, with no GitHub account. Clone the repository and drop the folder on this page instead; it is read in your browser the same way.
Can I import one folder or one branch?
Yes. Add /tree/branch to the URL for a branch, and /tree/branch/path for a single folder, and only the files under that path come in. A branch name with a slash in it does not work, so import the default branch instead.
What does it leave out by default?
The .git folder, dependency and vendored directories, lock files such as package-lock.json and go.sum, build output such as dist and target, and test files named as tests, such as api.test.ts or handler_test.go. Any of it can go back in under Adjust what's included. On our fresh clones the defaults removed about a fifth of the tokens, about a third of it tests.
Markdown or XML for a codebase?
FileConcat writes XML, Markdown or plain text, switched under the preview. Across five real codebases the switch changed the total by 0.24% to 1.13% of tokens (our measurement, August 2026). Use the one your prompt already uses.
Does a large repository work?
Up to about 100,000 files, yes: GitHub lists that many in one request. A bigger repository stops with a link to GitHub's ZIP of it. Download it and drop it here, and it is unpacked in your browser. Without an account, GitHub allows 60 requests an hour per network and each import uses one. When those are used up, the message says when they reset and links the same ZIP.
Is my code uploaded to a server?
Not to us. Your browser fetches the files directly from GitHub, so that request goes to them, and the bundle is built in your browser. There is no account to create.

One repository, one file, counted.

URL shapes, rate limits and very large repositories, in detail: GitHub import.