Context Assembler
Combine files and folders into one LLM-ready context block — like repomix or files-to-prompt, fully in your browser
Add files
Folder uploads preserve the directory tree. node_modules, .git, dist and build output are skipped automatically and never read.
Limits: up to 500 files, 1.0 MB each, 20.0 MB total. Heavier picks are reported, not lost.
Comma or newline separated. Names match any path segment; * is a glob.
Context output
Your assembled context appears here
Pick a folder or add files on the left
Files are read locally with the File API and never uploaded. The token estimate uses ≈4 characters/token — a rough guide, not an exact tokenizer count.
Examples
Assemble a TypeScript project
📁 Pick folder: my-app/
<file path="my-app/src/index.ts">
import { greet } from "./utils";
greet("world");
</file>
<file path="my-app/src/utils.ts">
export const greet = (n: string) => console.log(`Hello, ${n}!`);
</file>
<file path="my-app/package.json">
{ "name": "my-app", "type": "module" }
</file>Each file is wrapped in an XML tag with its relative path. The optional tree header gives the model a map of the project first.
Filter to one extension
Extensions: .ts,.tsx
Ignore: node_modules, *.test.ts, dist
→ Only non-test TypeScript files are included.Combine an extension allow-list with ignore globs to ship just the source files that matter for a code-review prompt.
Right-size the context window
Output: 12,480 chars · ≈3,120 tokens
→ Open Token Cost CalculatorThe token estimate shows how much of the context window the assembly uses before you paste it.
Examples
Assembling a small project
Files: src/index.ts, src/utils.ts, README.md
Ignore: node_modules/**, *.lockProject structure:
src/index.ts
src/utils.ts
README.md
<file path="src/index.ts">
import { add } from "./utils" ...
</file>Each file becomes an XML-tagged block with an escaped path; the tree header lets the model navigate the layout.
About this tool
Context Assembler merges files and folders into a single LLM-ready context block. Drop in source files, a documentation tree, or a whole folder, and it emits one document with each file wrapped in an XML-tagged block, a project tree at the top, and a token estimate — the same pattern popularized by repomix and files-to-prompt.
Glob ignore filters let you exclude node_modules, build output or secrets, and hard limits (file count, per-file size, and total size) keep the bundle within a model's context window while reporting what was skipped. File paths are XML-escaped so the output is safe to paste, and nothing is ever uploaded — files are read in your browser only.
How to use
Add files or a folder
Pick individual files or upload a folder; a project tree and per-file list build automatically.
Filter what's included
Use glob ignore patterns to drop node_modules, dist, images or any path you don't want in the context.
Check the token estimate
A running token estimate and size limits show whether the bundle fits your target model's context window.
Copy the assembled context
Copy one XML-tagged block with the tree header and every included file to paste into Claude, ChatGPT or an agent.
Use cases
Hand a repo to a model
Assemble an entire small project into one prompt so the model can reason across files without manual copy-paste.
Debug with full context
Bundle the relevant files and folder structure so a model review sees imports and layout, not isolated snippets.
Generate documentation
Give the model the source tree and files and ask for README, architecture or API docs grounded in the real layout.
Common mistakes
Mistake:Including node_modules or build output.
Fix:Add ignore globs like node_modules/**, dist/** and *.min.js so the bundle isn't flooded with generated code.
Mistake:Exceeding the context window.
Fix:Watch the token estimate and per-file size limits; trim to the relevant files rather than dumping the whole repository.
Mistake:Forgetting that paths are escaped.
Fix:Paths with &, < or > are XML-escaped inside the tags so the block stays valid; paste it as-is into the model.
Frequently asked questions
References & standards
Related tools
Prompt Template Builder
Write reusable prompt templates with {{variables}}, auto-fill the values, and copy the compiled prompt. Save your library of prompts locally — no AI calls, everything in your browser.
RAG Text Chunker
Split Markdown or plain text into LLM-friendly chunks by headings, words or characters with configurable overlap and metadata. Prep documents for RAG — all in your browser.
Token Cost Calculator
Compare LLM API costs across models with cache, batch, reasoning and traffic simulation — count tokens with a real tokenizer, refresh prices live, and export CSV/JSON/Markdown