Vigyata.AI
Is this your channel?

Ollama + Claude Code = 99% CHEAPER

209.8K views· 5,364 likes· 25:23· Apr 4, 2026

🛍️ Products Mentioned (7)

Full courses + unlimited support: https://www.skool.com/ai-automation-society-plus/about?el=free-claude-code All my FREE resources: https://www.skool.com/ai-automation-society/about?el=free-claude-code Apply for my YT podcast: https://podcast.nateherk.com/apply Work with me: https://uppitai.com/ My Tools💻 FREE MONTH voice to text: https://get.glaido.com/nate Code NATEHERK for 10% off VPS (annual plan): https://www.hostinger.com/vps/claude-code-hosting In this video I walk you through two different ways to run Claude Code completely free. The first method uses Ollama to run open source models locally on your own machine, and the second uses Open Router to access free models in the cloud. I cover everything from downloading and configuring models to the tradeoffs between local and cloud, and when you'd actually want to use open source models over something like Opus. "ANTHROPIC_BASE_URL": "https://openrouter.ai/api", "ANTHROPIC_AUTH_TOKEN": "YOUR OPEN ROUTER API KEY", "ANTHROPIC_API_KEY": "", "ANTHROPIC_MODEL": "openrouter/free", "ANTHROPIC_DEFAULT_SONNET_MODEL": "openrouter/free", "ANTHROPIC_DEFAULT_OPUS_MODEL": "openrouter/free", "ANTHROPIC_DEFAULT_HAIKU_MODEL": "openrouter/free", "ANTHROPIC_SMALL_FAST_MODEL": "openrouter/free", "CLAUDE_CODE_SUBAGENT_MODEL": "openrouter/free" Sponsorship Inquiries: 📧 nate@smoothmedia.co TIMESTAMPS 0:00 Intro 1:39 Open Source vs Closed Source Models 5:05 Method 1: Local Models with Ollama 8:45 Launching Claude Code with Ollama 16:16 When to Use Open Source Models 17:20 Method 2: Open Router 23:00 Open Source Limitations 24:55 Final Thoughts

About This Video

In this video, I show you two dead-simple ways to run Claude Code for free (or basically free) by swapping the “engine” under the hood. Claude Code is the harness (the car), and the model you talk to is the engine. By default that engine is Opus/Sonnet/Haiku through Anthropic, which is why you hit token/session limits. What we’re doing here is plugging Claude Code into open-weight models instead—either locally on your machine with Ollama or in the cloud with free models through OpenRouter. First, I walk through the local setup: install Ollama, pull a model (I demo Qwen), run it in terminal, then launch Claude Code against it. I also show why some open-source models “misbehave” inside Claude Code (tool calling, JSON protocol, context window issues) and how I fix context by creating a custom Ollama model with a larger context setting so tool calls show up properly. Then I cover the OpenRouter method: point Claude Code’s environment variables to OpenRouter, paste your API key, and make sure you override every default model variable so you don’t accidentally get charged for Haiku/Sonnet. My takeaway: there’s no truly free lunch—local needs hardware, cloud has limits—but you can get Claude Code 50–100x cheaper and keep working when Claude is down or you hit limits.

Frequently Asked Questions

🎬 More from Nate Herk | AI Automation