HTML / FREECODECAMP WORKSHOP COMPANION
freeCodeCamp: Build a Heart Icon
Draw a small heart with inline SVG. Learn how the SVG container, a path, dimensions and fill work together to describe a scalable shape.

Which step do you need help with?
Choose any step. You can move freely without completing earlier steps here.
Written guidance is available to everyone. Step videos require a signed-in Code Zone account with video access.
What you will build
Draw a small heart with inline SVG. Learn how the SVG container, a path, dimensions and fill work together to describe a scalable shape.
Follow 6 small changes, from the supplied starter to the finished HTML structure. This workshop focuses on HTML; native browser styling may look plain.
What you will learn
- svg: SVG container
- body: Document body
- path: SVG path
- d: Path data
- width: Width
- height: Height
- viewBox: SVG coordinate system
- fill: Fill color
How to use this companion
- Build on freeCodeCamp. Keep its workshop open in another tab. Your code, checks and course progress stay there.
- Come here when you need context. Open the matching step for the task, reasoning, definitions and expected preview.
- Watch a focused explanation. Member videos show how the instructions become code and what changes in the preview.
- Try it yourself. Return to freeCodeCamp and run its checks before moving on.
Skills you can use beyond this workshop
Practice translating requirements into small changes, nesting elements in the right place, reading the browser result and checking reliable references. These habits help you understand unfamiliar code without memorizing every element or property.
Ready to work through the workshop?
Choose a step above whenever you need guidance, or start coding in the official workshop.
Independent guidance from The Code Zone, not affiliated with or endorsed by freeCodeCamp. Complete official work and certification requirements on freeCodeCamp. Curriculum checked November 15, 2026. Curriculum source (opens in a new tab).