# OpenAI’s Codex Is Now Completely FREE - Run It 100% Locally with Ollama (No Limits, No API
**作者**: WorldofAI
**日期**: 2026-05-27T22:13:21.000Z
**来源**: [https://x.com/intheworldofai/status/2059759892873851335](https://x.com/intheworldofai/status/2059759892873851335)
---

BREAKING: You can now run OpenAI’s Codex for FREE with Ollama
No API costs. No rate limits. 100% local on your machine.
Here’s exactly how to run Codex (both the desktop app and CLI) locally using powerful open-source models like Gemma 4, Qwen 3.6, and DeepSeek V4.
For years, Codex has been one of the most powerful coding agents but it was locked behind OpenAI’s API pricing and rate limits.
That just changed.
Ollama v0.24+ now has official, native support for both Codex App and Codex CLI. You can now run the full Codex experience completely locally with open models that rival or even beat the original experience.
Why This Is a Big Deal
- Zero cost after setup
- Unlimited usage (no more rate limits)
- Full privacy - your code never leaves your machine
- Access to strong multimodal and tool-calling models
- Codex App’s built-in browser and review mode work perfectly with local models
Here’s the complete setup.
## 1. Codex App (Desktop) – The Easiest Way
The Codex desktop app now works beautifully with Ollama.
Quick Setup:
1. Update Ollama to the latest version (v0.24 or newer)
2. Run this command:Bash
```
ollama launch codex-app
```
3. Choose your model when prompted (or run with a specific one):
```
ollama launch codex-app --model gemma4:31b
```
Features that now work locally:
- Built-in browser (visually edit websites by annotating directly on the page)
- Review mode (leave comments and iterate on code changes)
- Full chat interface inside the app
To restore your original Codex settings later:
```
ollama launch codex-app --restore
```
## 2. Codex CLI – For Terminal Power Users
If you prefer working in the terminal:
```
npm install -g @openai/codex
```
Then start it with the open-source flag:
```
codex --oss
```
To use a specific model:
codex --oss -m gemma4
codex --oss -m qwen3.6
codex --oss -m deepseek-v4
Recommended Models Right Now
- gemma4:31b → Excellent all-rounder, strong reasoning
- qwen3.6 → Outstanding coding performance
- kimi-k2.6:cloud → Great if you want vision support
- DeepSeek V4 → Very strong at complex tasks
Pro tip before downloading big models:Go to whatmodelscanirun.com - it instantly tells you which models your GPU and VRAM can run comfortably.
Built-in browser:

Codex App can open local servers and sites in its built-in browser. Annotate directly on the page to request changes.
Review mode:

Use review mode to inspect code changes, leave comments, and iterate on fixes without leaving the app.
## Bottom Line
Ollama just turned Codex from a paid, rate-limited tool into a fully local, unlimited coding agent, Whether you use the beautiful desktop Codex App or the CLI, you can now get a top-tier coding experience completely free and private.
The era of depending on OpenAI’s servers for Codex is officially over.
Watch the full setup video here: → https://youtu.be/qo40REk9wNU
Are you going to try the Codex App or the CLI first? Which model are you planning to run with it?
Drop your answers below - curious to see how everyone is using this new local Codex setup.
## 相关链接
- [WorldofAI](https://x.com/intheworldofai)
- [@intheworldofai](https://x.com/intheworldofai)
- [817K](https://x.com/intheworldofai/status/2059759892873851335/analytics)
- [whatmodelscanirun.com](https://whatmodelscanirun.com/)
- [https://youtu.be/qo40REk9wNU](https://youtu.be/qo40REk9wNU)
- [Upgrade to Premium](https://x.com/i/premium_sign_up)
- [6:13 AM · May 28, 2026](https://x.com/intheworldofai/status/2059759892873851335)
- [817.4K Views](https://x.com/intheworldofai/status/2059759892873851335/analytics)
- [View quotes](https://x.com/intheworldofai/status/2059759892873851335/quotes)
---
*导出时间: 2026/5/31 15:15:52*
---
## 中文翻译
# OpenAI 的 Codex 现在完全免费 - 使用 Ollama 在本地 100% 运行(无限制,无 API 密钥)
**作者**: WorldofAI
**日期**: 2026-05-27T22:13:21.000Z
**来源**: [https://x.com/intheworldofai/status/2059759892873851335](https://x.com/intheworldofai/status/2059759892873851335)
---

**重磅消息:** 你现在可以使用 Ollama 免费运行 OpenAI 的 Codex
无 API 费用。无速率限制。100% 在你的本地机器上运行。
以下是使用 Gemma 4、Qwen 3.6 和 DeepSeek V4 等强大的开源模型,在本地运行 Codex(包括桌面应用程序和 CLI)的具体方法。
多年来,Codex 一直是最强大的代码代理之一,但它被锁定在 OpenAI 的 API 价格和速率限制之后。
这种情况刚刚发生了改变。
Ollama v0.24+ 现已正式支持 Codex 应用和 Codex CLI。你可以使用能够媲美甚至超越原始体验的开源模型,在本地完整运行 Codex。
**为什么这是一件大事**
- 初始设置后零成本
- 无限使用(不再有速率限制)
- 完全隐私 - 你的代码永远不会离开你的机器
- 可访问强大的多模态和工具调用模型
- Codex 应用内置的浏览器和审查模式与本地模型完美配合
以下是完整的设置指南。
## 1. Codex 应用 - 最简单的方式
Codex 桌面应用现在可以与 Ollama 完美配合使用。
**快速设置:**
1. 将 Ollama 更新到最新版本(v0.24 或更新版本)
2. 运行此命令:Bash
```
ollama launch codex-app
```
3. 在提示时选择你的模型(或运行特定模型):
```
ollama launch codex-app --model gemma4:31b
```
现在可以在本地使用的功能:
- 内置浏览器(通过在页面上直接标注来可视化编辑网站)
- 审查模式(留下注释并迭代代码更改)
- 应用内的完整聊天界面
如果稍后要恢复你原来的 Codex 设置:
```
ollama launch codex-app --restore
```
## 2. Codex CLI – 适合终端高级用户
如果你更喜欢在终端中工作:
```
npm install -g @openai/codex
```
然后使用开源标志启动它:
```
codex --oss
```
要使用特定模型:
codex --oss -m gemma4
codex --oss -m qwen3.6
codex --oss -m deepseek-v4
**目前推荐的模型**
- gemma4:31b → 优秀的全能型,强大的推理能力
- qwen3.6 → 卓越的编码性能
- kimi-k2.6:cloud → 如果你想获得视觉支持,这是个不错的选择
- DeepSeek V4 → 在复杂任务中表现非常强劲
下载大模型前的专业提示:访问 whatmodelscanirun.com - 它会立即告诉你你的 GPU 和 显存 可以流畅运行哪些模型。
**内置浏览器:**

Codex 应用可以在其内置浏览器中打开本地服务器和站点。直接在页面上进行标注以请求更改。
**审查模式:**

使用审查模式检查代码更改、留下注释,并在无需离开应用的情况下迭代修复。
## 结论
Ollama 刚刚将 Codex 从一个付费、有速率限制的工具转变为了完全本地化、无限的代码代理。无论你是使用精美的桌面 Codex 应用还是 CLI,你现在都可以完全免费且私密地获得顶级编码体验。
依赖 OpenAI 服务器运行 Codex 的时代正式结束了。
在此观看完整的设置视频:→ https://youtu.be/qo40REk9wNU
你打算先尝试 Codex 应用还是 CLI?你计划使用哪个模型来运行它?
请在下方留下你的答案 - 很高兴看到大家如何使用这个新的本地 Codex 设置。
## 相关链接
- [WorldofAI](https://x.com/intheworldofai)
- [@intheworldofai](https://x.com/intheworldofai)
- [817K](https://x.com/intheworldofai/status/2059759892873851335/analytics)
- [whatmodelscanirun.com](https://whatmodelscanirun.com/)
- [https://youtu.be/qo40REk9wNU](https://youtu.be/qo40REk9wNU)
- [升级到 Premium](https://x.com/i/premium_sign_up)
- [6:13 AM · May 28, 2026](https://x.com/intheworldofai/status/2059759892873851335)
- [817.4K Views](https://x.com/intheworldofai/status/2059759892873851335/analytics)
- [View quotes](https://x.com/intheworldofai/status/2059759892873851335/quotes)
---
*导出时间: 2026/5/31 15:15:52*