Blog Article

Can an AI Agent Really Run Autonomously for 24 Hours? I Tested Claude Code and Codex Side by Side

A head-to-head test of Claude Code (Opus 5) and Codex (GPT-5.6 Sol) running the same 24-hour autonomous build prompt. Neither agent ran the loop, one of them spun up

Short answer: no. Not from a desktop app, and not from a prompt alone.

I gave the same master prompt to Claude Opus 5 running in Claude Code and to GPT-5.6 Sol running in Codex, both inside their respective desktop apps, side by side on one screen. The instruction was simple: you are an autonomous founder engineer, you have 24 hours of continuous run time, take a micro SaaS from nothing to a live working product. No human will answer questions.

I did zero research ahead of time. I did not pick the niche, the stack, or the pricing. I wanted to see which one followed instructions and which one shipped something a real person could actually use.

Twenty five hours later, the loop had failed on both.

What the prompt actually asked for

This is the most reusable part of the whole experiment, so here is what was in it.

Mission. Research and select one underserved micro SaaS niche. Criteria: a real specific problem, buildable by one agent in 24 hours, with a clear reason somebody would pay $5 to $20 a month. Log three candidate ideas and why you picked the winner in decisions.md before writing any code.

Build it. Web app deployed and publicly reachable. Package it as a business: landing page with pricing, working signup and auth, and a Stripe test mode checkout that completes end to end. Write one launch asset, a short launch post in X or Reddit style, saved to a marketing launch file.

Definition of done. Public URL loads and the core feature works for a brand new user. Signup, login, and logout all function. Stripe test mode checkout completes and gates a paid feature. Landing page states the problem, solution, and price. A README explains what it is and how to run it locally. No placeholder text, dead links, or fake testimonials anywhere.

Operating rules. Deploy early within the first three hours and redeploy continuously. A live ugly product beats a perfect local one. Prefer boring reliable stack choices over impressive ones. Never mark a task complete unless you have actually run it and observed it working. If something is broken, say so in the log. Stripe must stay in test mode. No real payments, no personal data, no emails to real people. Scope down before you fall behind, and log the cut.

Logging, required, do not skip. Maintain checkpoint.md every hour. Append an entry with the hour, status (on track, behind, blocked), what shipped that hour with commit references, what is broken right now, the current biggest risk, and one sentence to camera about what it is doing and why.

I also added one line by hand to both terminals before hitting go: create a new Stripe business workspace for whatever idea you decide on. Each agent got its own private GitHub repo.

Then, full send.

What happened in the first few minutes

Codex moved first. It announced it was starting the 24-hour build and created the two required log files before anything else, exactly as instructed. Claude was a little behind but got going on research.

The one moment of hand-holding in the entire run came early. I noticed ChatGPT selecting Convex for its stack, so I connected it on the spot. That was it. After that I left both of them alone and came back the next day.

Twenty five hours later

Claude had stopped working roughly 22 hours earlier. Codex had declared itself finished in 1 hour and 4 minutes.

Neither one wrote hourly checkpoints for 24 hours, because neither one ran for 24 hours. The duration instruction and the logging instruction failed together, which makes sense in hindsight: the hourly checkpoint was the mechanism that would have forced pacing. When the loop collapsed, the pacing collapsed with it.

Claude's stop reason was the part I did not see coming. It hit a Vercel 100 deployment per day account limit.

I went to look at my Vercel dashboard, and I counted out loud: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11. Eleven separate Vercel projects for one app. Below all of them sat Codex's single DMARC deployment.

I never told it to do that. The prompt said deploy early and redeploy continuously. It never said "into one project." That is on me.

What each one actually built

Claude built CrawlGap. The pitch: "Your robots.txt says AI crawlers are welcome. Your server disagrees." Priced at $12 a month. It is a genuinely good niche, specific and defensible, and it picked it with no input from me.

I tested it on my own domain, clearmud.ai. Nothing came back. I pressed scan again and got "we read your robots.txt," and still nothing. So I tried to log in, then tried to sign up instead. Account creation failed too.

It did set up Stripe in test mode, which was the single hardest item on the checklist. Cool, and at the same time, not fully functional. The prompt explicitly said never mark a task complete unless you have run it and observed it working. CrawlGap was marked done with a broken scanner and a broken signup.

Codex built a DMARC report reader. The pitch: "DMARC reports are machine-readable. Now they are human-usable." It turns XML and Gzip aggregate reports into a ranked failure list without forwarding mail, changing DNS, or uploading sensitive report contents. Open the attachments you already receive, put failed traffic first.

I clicked "Start pro in test mode," created an account with my own credentials, and got in. Signup and login worked end to end. One minor bug, and that was it.

Afterward I went back into its research trail just to see how it landed on DMARC. It started with web searches, then inspected Stripe and built that side of things. Watching the reasoning was honestly the most interesting part of the review.

Who won, and why that is the less useful question

Codex clearly wins here, but they both failed at the thing I actually asked for.

Codex wins on operational restraint. It shipped working auth, it shipped a functioning Stripe test mode checkout, and it did not trash my Vercel account or leave me a pile of demo projects to go delete by hand. Claude went crazy and created 11 duplicate projects. Codex did not.

The credit Claude does deserve: it understood the mission and it told me exactly what the limitation was. The deployment cap showed up in the log instead of failing silently.

And to be straight about it, neither product stands out to me as a product. The winner won on judgment and cleanup cost, not on the idea.

The actual lesson

The reason I chose these desktop apps is that I thought they would be intelligent enough to schedule their own work inside the app and follow the timeline in the master prompt. Neither one did that. Both read an open-ended time budget as "finish and stop."

That is a prompt bug before it is a model failure. Here is what I would change:

  • Do not ask a desktop agent to run for 24 hours. Continuous or paced work needs an external scheduler. The model will not invent its own cadence, no matter how detailed your hour-by-hour timeline is.
  • Constrain the deployment target by name. Say "one Vercel project, redeploy into it." "Redeploy continuously" with no target is how you get 11 projects and a rate limit.
  • Check the account-level blast radius before you launch anything unattended. Deployment quotas, Stripe workspaces, repo creation. Assume the cleanup is manual, because it is. I was genuinely nervous to go look at my Stripe account.
  • Front-load the decision log. Requiring three candidate ideas with rationale in decisions.md before any code is the part of the prompt that worked on both runs. It is what made the reasoning reviewable after the fact.
  • Verify the definition of done yourself. Both agents reported finished builds. Only one had working auth. Sign up, log in, run the core feature, complete the checkout, as a brand new user, on the live URL.
  • Keep Stripe in test mode and say so explicitly. Both models honored it and both got test mode checkout working. That instruction is solved.

Today was all about experimentation. It was about trying something new, and the useful finding is not "this model beats that model." It is that autonomous long-run loops need explicit scheduling and infrastructure guardrails, not just a well-written prompt. Maybe this is my fault. Maybe I should have held it more.

I am not an AI expert. I am building in public and sharing what actually works, including when it does not.

If you want to see me make a video on a specific topic, drop a comment. Tell me who you are, what you do, who your target audience is, and what your question is, and I will add a video to my queue tailored to you.

My name is Marcelo. This is Clear Mud, and Clarity Matters.

Watch the full experiment: https://www.youtube.com/watch?v=oqv66E-KrFE

Watch the full walkthrough on YouTube.

Watch on YouTube