Form UX Optimizer
Skill9 starsChanged 8 months agoMITView on GitHub
Reviews web forms for usability issues — field ordering, validation messages, error states, and accessibility.
In this repository61 other files it gives its agents.
- Accessibility Audit HelperSkill
- Agent Context File WriterSkill
- Agent Evaluation Framework BuilderSkill
- AI Feature Spec WriterSkill
- API Documentation GeneratorSkill
- REST API Endpoint DesignerSkill
- Architecture ExplainerSkill
- Article RepurposerSkill
- Auth Flow PlannerSkill
- Blog Outline GeneratorSkill
- Breaking Change DetectorSkill
- Bug Root Cause AnalyzerSkill
- Caching Strategy AdvisorSkill
- Changelog CuratorSkill
- Code Review ChecklistSkill
- Database Schema ReviewerSkill
- Docker Compose GeneratorSkill
- Documentation Gap FinderSkill
- Edge Case DiscoverySkill
- Error Log SummarizerSkill
- FAQ GeneratorSkill
- Flaky Test AnalyzerSkill
- Git Commit WriterSkill
- Hallucination Risk ReviewerSkill
- Hybrid Search ArchitectSkill
- Incident Postmortem WriterSkill
- Issue to PR PlannerSkill
- Landing Page Copy ImproverSkill
- LangGraph State Machine DesignerSkill
- LLM Cost OptimizerSkill
- LLM Tracing and Observability SetupSkill
- MCP Integration AssistantSkill
- MCP Server BuilderSkill
- Migration Guide WriterSkill
- Newsletter Summary WriterSkill
- Observability ChecklistSkill
- Playwright Test BuilderSkill
- PR Description WriterSkill
- Prompt Injection Defense AuditorSkill
- Prompt RefinerSkill
- Prompt Version Control WorkflowSkill
- RAG Chunking Strategy AdvisorSkill
- RAG Workflow PlannerSkill
- React Component ReviewerSkill
- README WriterSkill
- Refactor PlannerSkill
- Release Notes GeneratorSkill
- Responsive Layout ReviewerSkill
- SDK Quickstart WriterSkill
- SEO Content OptimizerSkill
- SEO Metadata GeneratorSkill
- Social Post Thread WriterSkill
- Sprint Summary GeneratorSkill
- SQL Query OptimizerSkill
- Stack Trace AnalyzerSkill
- Technical Blog Post WriterSkill
- Tech Debt AuditorSkill
- Troubleshooting Guide BuilderSkill
- Unit Test ImproverSkill
- Unit Test WriterSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
9 rules. About 0 are common, 5 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈5
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 19
Use this before shipping a registration, checkout, contact, or any data-entry form — especially when your form has a high abandonment rate …
- Very specific: line 35
Add the instructions below to your .cursorrules or paste them into the Cursor AI pane.
- Distinctive: line 43
When asked to review a form for UX, follow this checklist systematically:
- Very specific: line 48
Every input must have a visible <label> element (not just placeholder text)
- Very specific: line 64
Search fields must use type="search"
- Distinctive: line 79
Don't validate on every keystroke — it's annoying while the user is still typing
- Very specific: line 93
Every form must have a <form> element (not just <div>)
- Distinctive: line 105
After a successful submission, give clear feedback — don't just clear the form silently
- Distinctive: line 177
Run the axe browser extension on your form after implementing fixes to catch any remaining accessibility issues.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Form UX Optimizer
What this skill does
This skill reviews the code and design of web forms to identify usability and accessibility issues. It checks for poor field ordering, confusing labels, missing or unhelpful error messages, incorrect input types, broken keyboard navigation, and accessibility violations. The output is a prioritized list of specific improvements with code examples for each fix.
Use this before shipping a registration, checkout, contact, or any data-entry form — especially when your form has a high abandonment rate or you're getting support requests about users not knowing what to enter.
How to use
Claude Code / Cline
Copy this file to .agents/skills/form-ux-optimizer/SKILL.md in your project root.
Then ask:
- "Use the Form UX Optimizer skill to review our checkout form in
CheckoutForm.tsx." - "Review this registration form for UX and accessibility issues using the Form UX Optimizer skill."
Provide the form component code and, if available, any validation logic.
Cursor
Add the instructions below to your .cursorrules or paste them into the Cursor AI pane. Provide the form code to review.
Codex
Paste the form HTML/JSX and validation code. Ask Codex to follow the instructions below.
The Prompt / Instructions for the Agent
When asked to review a form for UX, follow this checklist systematically:
Category 1 — Field design and labeling
Labels
- Every input must have a visible
<label>element (not just placeholder text) - Labels must be associated with inputs via
for/htmlForor wrapping - Placeholder text must not be used as a substitute for labels — it disappears on input and has poor contrast
- Required fields must be clearly marked (e.g., asterisk with a legend explaining it means required)
Field order
- Fields should follow a logical, natural sequence (name before email, shipping before billing)
- Related fields should be grouped visually and in DOM order
- The most important or most-filled field should come first, not last
Input types
- Phone number fields must use
type="tel"(shows numeric keyboard on mobile) - Email fields must use
type="email"(enables autocomplete and basic validation) - Number inputs must use
type="number"where appropriate - Date inputs must use
type="date"or a proper date picker, not three separate text inputs - Password fields must use
type="password" - Search fields must use
type="search"
Autocomplete
- Common fields should have
autocompleteattributes set:autocomplete="email",autocomplete="given-name",autocomplete="tel",autocomplete="current-password",autocomplete="new-password", etc. - This enables browser autofill and password manager integration
Category 2 — Validation and errors
Error messages
- Error messages must be specific: "Email is required" is better than "Invalid input"; "Password must be at least 8 characters" is better than "Invalid password"
- Errors should tell the user what to do, not just what went wrong: "Enter a valid email address" not "Email invalid"
- Errors must appear near the field they relate to, not only at the top of the form
- Error messages must be associated with their input via
aria-describedbyoraria-errormessage
Validation timing
- Don't validate on every keystroke — it's annoying while the user is still typing
- Validate on
blur(when the user leaves a field) for format errors - Validate on submit for completeness
Inline validation
- Show a success indicator when a field is correctly filled (a checkmark) — reduces anxiety, especially for passwords and usernames
- For password strength, use a visual strength meter, not just a minimum length error
Error state styling
- Error states must not rely on color alone (red border alone fails WCAG for color-blind users — add an icon or text)
- Error state must be clearly visually distinct from the default state
Category 3 — Accessibility
- Every form must have a
<form>element (not just<div>) - Submit button must be a
<button type="submit">or<input type="submit">— not a<div>with anonClick - The form must be fully operable with a keyboard alone (Tab to advance, Shift+Tab to go back, Enter to submit)
- Focus indicators must be visible — never
outline: nonewithout a replacement aria-required="true"should be present on required fields in addition to HTMLrequiredaria-invalid="true"should be set on fields with validation errorsaria-live="polite"region should announce error messages to screen readers when they appear
Category 4 — Form-level UX
- The submit button label should describe the action: "Create Account", "Place Order", "Send Message" — not just "Submit"
- Show a loading state on the submit button while the form is being processed
- After a successful submission, give clear feedback — don't just clear the form silently
- For multi-step forms, show a progress indicator
- For long forms, consider grouping with
<fieldset>and<legend>
Output format
## Form UX Review — [Form Name]
### Critical Issues (accessibility violations or blocking UX problems)
#### 1. [Issue title]
- **Field / Location**: [Field name or line number]
- **Problem**: [What's wrong and why it matters]
- **Fix**: [Specific code change with example]
### High-Priority Issues (significant UX degradation)
[Same format]
### Warnings (minor issues or best practice gaps)
[Same format]
### What's Already Good
[Brief acknowledgment of things done well]Example
Input to Agent:
"Use the Form UX Optimizer skill on this form:
<div> <input placeholder="Email" onChange={...} /> <input placeholder="Password" type="password" onChange={...} /> <div onClick={handleSubmit} className="btn">Go</div> </div> ```"
Output from Agent:
Form UX Review — Login Form
Critical Issues
1. No
<label>elements — placeholders used as labels
- Problem: When the user starts typing, the placeholder disappears and they lose the field context. Screen readers also cannot reliably read placeholders as labels.
- Fix:
<label htmlFor="email">Email</label> <input id="email" type="email" placeholder="you@example.com" autocomplete="email" />2. Submit is a
<div>, not a<button>
- Problem: A
<div>is not keyboard-accessible by default, is not announced as a button by screen readers, and doesn't submit the form on Enter.- Fix:
<button type="submit">Sign in</button>— rename "Go" to something descriptive.3. No
<form>wrapper
- Problem: Without a
<form>element, the browser's built-in form submission, validation, and Enter-to-submit behavior is lost.- Fix: Wrap in
<form onSubmit={handleSubmit}>and remove theonClickfrom the button.High-Priority Issues
4. Email input missing
type="email"
- Problem: Without
type="email", mobile devices show a standard keyboard instead of the optimized email keyboard. Browser-level email validation is also disabled.- Fix:
<input type="email" ... />
Notes
- This skill reviews code; it doesn't test the form in a browser. Some issues (focus order, screen reader behavior) require manual testing or automated tools like axe-core.
- For checkout forms, the two highest-impact fixes are usually: (1) adding autocomplete attributes and (2) improving error messages. These alone can noticeably improve completion rates.
- Run the axe browser extension on your form after implementing fixes to catch any remaining accessibility issues.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

