Codex Prompt for Website Design: 10 Build Briefs That Work
10 Codex prompts for website design: AGENTS.md setup, design tokens, page builds from section lists, reference images, responsive and accessibility checks.

A Codex prompt for website design works best as a build brief: the pages and sections in order, your design tokens, the stack, reference images to attach, and the commands Codex must run before it reports done. The 10 prompts below cover repo setup, page builds, design systems, responsive and accessibility checks, and a screenshot review loop. Put the lasting rules in AGENTS.md and the job in the task prompt.
For a complete brief with an AGENTS.md section, CSS tokens, a page plan and a done report, use the Codex site build brief prompt.
Set up the repo
1. AGENTS.md for a website
Write an AGENTS.md section for this [framework] site: the install, dev, build and test commands, where design tokens live, naming rules for components, and these do-nots: [list]. Keep it under 40 lines.
2. Design tokens file
Create [tokens file path] with CSS custom properties for these colors [hex values], fonts [names], spacing scale [values] and radius [value]. Do not add values I did not give; list what is missing.
3. Content files first
Before building pages, move this copy [paste] into [data file] with one field per heading, price and button label. Pages must read from that file, never hard-code copy.
Build pages
4. Page from a section list
Build the [page] page with these sections in order: [list]. One component per section in [components folder]. Use only tokens from [tokens file]. Leave TODO(owner) where copy is missing.
5. Match a reference image
I attached [image]. Copy its layout and spacing for the [section], not its logo, text or photos. Then screenshot your version at [widths] and list the differences you could not close.
6. Component library page
Add a /styleguide page showing every button, card, form field and heading style in all states (default, hover, focus, disabled), using only the tokens file.
Check the work
7. Responsive pass
Run [screenshot command] at 375, 768 and 1280 pixels wide for [pages]. Fix overflow, cut-off text and tap targets smaller than [size]. Report each fix with the file changed.
8. Accessibility pass
Check [pages] for one h1 per page, heading order, alt text, form labels, color contrast against [background] and visible keyboard focus. Fix what you can and list anything that needs a design decision.
9. Performance pass
List every image over [size] and every script loaded on [page]. Propose fixes and wait for my approval before adding any dependency.
Report and hand off
10. Done report
Before you finish, run [build command] and [screenshot command], then report: files changed, each command with pass or fail, screenshots saved, TODO placeholders left and questions for me.
Worked example: a pottery studio site
In the prompt's sample, a small studio wants a home page, a classes page and a contact page built in Astro. The brief gives Codex four rules for AGENTS.md (run the build and a screenshot script before done, use the tokens file, take copy only from two JSON files, no new dependencies), turns five color and font choices into CSS variables, and flags what is missing (a hover color and a font scale). The task prompt lists each page's sections, says what to take from two attached reference images and what not to copy, and ends with a self-check loop and a report that must list the placeholder steps the owner still has to write.
Codex notes, checked on Dec 1, 2026
OpenAI's Codex docs say Codex reads AGENTS.md files before doing any work, and the /init command creates a starter file. The Codex CLI accepts images with the --image or -i flag, as comma-separated paths or a repeated flag, so you can pass reference screenshots with the first prompt. Codex checks its own work with the commands you give it, so a screenshot script in your repo is what makes the review loop possible. PromptDig is not affiliated with OpenAI.
Tips
- Keep copy, prices and claims in data files; Codex should arrange them, not write them.
- Say what to take from each reference image and what to leave.
- Ask for TODO placeholders instead of filler text, and a list of them in the report.
- Approve new dependencies yourself.
Related on PromptDig
For the agent's standing rules, see the coding agent system prompt and the system prompt for coding agents guide. To review what Codex changed, use the Codex code review prompts. Working in Claude Code instead? Try the Claude Code website design prompts, and for which instruction file loads where, read AGENTS.md vs CLAUDE.md vs Cursor rules. More in the Agents hub, browse all prompts, or share your own Codex brief.