AI
Figma to code
Use Figma MCP to move between design and code with SGDS as your source of truth.
What this means in simple terms
Figma MCP lets your AI tool read useful information from Figma, not just a screenshot.
Instead of guessing from a flat image, the AI can understand structure like frames, layout, spacing, components, variants, and styles.
If your team uses SGDS, this gets even more useful because the AI has a proper design system to follow instead of inventing its own patterns.
Why this helps SGDS teams
Without SGDS, AI may generate something that looks close but uses the wrong component, the wrong variant, or inconsistent spacing and behaviour.
With SGDS, the AI can follow a shared source of truth. That means more consistent outputs, less cleanup, and smoother handoff between designers and developers.
Choose your workflow
This is the best starting point if you already have screens in Figma and want the AI to help translate them into SGDS-aligned code.
Go to your Figma screen
Locate and select your Figma frame.
Give your AI the Figma context
With the Figma MCP server enabled, share a Figma link to the frame or node.
- Click the Dev Mode toggle or use the keyboard shortcut
Shift + D. - Under MCP, click Copy example prompt.
Ask for SGDS-aligned output
Be explicit that you want SGDS-aligned output.
Review before handoff
Before handing it off, check that the output uses the right SGDS components and variants, keeps the same hierarchy as the design, and includes any missing states or accessibility considerations.
Use this workflow when your team already has working UI in code and you want to bring it into Figma in a way that is still useful for design work.
Start from the real coded page
Start from the real implemented page, view, or component. Pick the exact coded screen you want to bring into Figma.
Ask the AI to move it into Figma
Ask the AI to capture or recreate the coded screen in Figma.
Rebuild with SGDS logic
Do not treat this as just a screenshot exercise. The goal is to rebuild the screen with the right SGDS logic:
- correct components
- correct variants
- correct spacing and tokens
- reusable design structure where possible
Tidy the Figma file for reuse
Once the screen is in Figma, tidy it up so it is usable for future design work. Rename frames properly, check hierarchy and spacing, and replace anything temporary with the correct SGDS library component if needed.
Useful skills
These skills are especially helpful in this workflow:
figma-implement-designfor turning Figma designs into codefigma-generate-designfor moving code or a live page into Figmafigma-usefor creating or editing things directly in a Figma filesgds-componentsfor choosing the correct SGDS componentsgds-utilitiesfor applying SGDS tokens and spacing correctly