[Bug] File content exceeds maximum token limit with large files
Resolved 💬 3 comments Opened Dec 20, 2025 by solrevdev Closed Dec 24, 2025
Bug Description
I get the following error every prompt it seems. I use sonnet 4.5 due to being on pro plan, it works around it but you should know about it if you don't already :
⏺ Read(.bash_functions)
⎿ Error: File content (28810 tokens) exceeds maximum allowed tokens (25000). Please use offset and limit
parameters to read specific portions of the file, or use the GrepTool to search for specific content.
Environment Info
- Platform: darwin
- Terminal: Apple_Terminal
- Version: 2.0.74
- Feedback ID: c5869f2f-a424-44c0-9912-0b5f6c17c363
Errors
[{"error":"MaxFileReadTokenExceededError: File content (28810 tokens) exceeds maximum allowed tokens (25000). Please use offset and limit parameters to read specific portions of the file, or use the GrepTool to search for specific content.\n at Hw_ (/$bunfs/root/claude:957:12204)\n at async call (/$bunfs/root/claude:966:1005)\n at async ho7 (/$bunfs/root/claude:2142:17437)\n at processTicksAndRejections (native:7:39)","timestamp":"2025-12-20T14:19:02.748Z"},{"error":"MaxFileReadTokenExceededError: File content (29902 tokens) exceeds maximum allowed tokens (25000). Please use offset and limit parameters to read specific portions of the file, or use the GrepTool to search for specific content.\n at Hw_ (/$bunfs/root/claude:957:12204)\n at async call (/$bunfs/root/claude:966:1005)\n at async <anonymous> (/$bunfs/root/claude:3440:1507)\n at processTicksAndRejections (native:7:39)","timestamp":"2025-12-20T14:21:43.883Z"},{"error":"MaxFileReadTokenExceededError: File content (29902 tokens) exceeds maximum allowed tokens (25000). Please use offset and limit parameters to read specific portions of the file, or use the GrepTool to search for specific content.\n at Hw_ (/$bunfs/root/claude:957:12204)\n at async call (/$bunfs/root/claude:966:1005)\n at async <anonymous> (/$bunfs/root/claude:3440:1507)\n at processTicksAndRejections (native:7:39)","timestamp":"2025-12-20T14:22:28.025Z"},{"error":"MaxFileReadTokenExceededError: File content (29902 tokens) exceeds maximum allowed tokens (25000). Please use offset and limit parameters to read specific portions of the file, or use the GrepTool to search for specific content.\n at Hw_ (/$bunfs/root/claude:957:12204)\n at async call (/$bunfs/root/claude:966:1005)\n at async <anonymous> (/$bunfs/root/claude:3440:1507)\n at processTicksAndRejections (native:7:39)","timestamp":"2025-12-20T14:22:41.494Z"}]This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗