[{"data":1,"prerenderedAt":254,"buildId":255},["ShallowReactive",2],{"page-\u002Fbuild\u002Fbuild-a-website-with-ai":3},{"id":4,"title":5,"body":6,"description":236,"extension":237,"how_to_steps":238,"hub":180,"meta":239,"navigation":240,"path":241,"primary_keyword":242,"published_at":243,"schema_types":244,"seo":248,"status":249,"stem":250,"updated_at":251,"wave":252,"__hash__":253},"pages\u002Fbuild\u002Fbuild-a-website-with-ai.md","Build a Website With AI - and Understand Every Line",{"type":7,"value":8,"toc":228},"minimark",[9,13,18,21,24,27,30,44,48,56,59,67,77,95,98,101,105,124,131,157,164,167,175,183,187,190,197,200,203,206,209,213,216,219,222,225],[10,11,12],"p",{},"To build a website with AI, describe what a visitor needs to do, ask for a small set of files, and open those files in a real browser.\nRead the markup, check the visitor's task, and keep a copy you can change without signing back into the AI tool.\nYou can practice the whole process with one page about a fictional repair cafe.",[14,15,17],"h2",{"id":16},"the-thesis","The thesis",[10,19,20],{},"Suppose the repair cafe has moved from the main doors to the north entrance.\nA visitor leaving home needs to find the new entrance on a phone, even if the page's photo takes a while to load.\nYou need to change that entrance without asking an AI tool to regenerate six sections and hoping it leaves the time alone.\nThose are two different tests of the same site: can the visitor use it, and can you look after it?",[10,22,23],{},"This is what we mean by HTML For All.\nAI can start a draft that would otherwise take you an afternoon of unfamiliar syntax.\nThe draft becomes useful when you can point to the source of a sentence, change it, and show that a visitor can still find it afterward.\nYou don't have to memorize every element to do that.\nYou have to be able to read the part that makes a claim or controls an action, and to find out what happens when you change it.",[10,25,26],{},"HTML describes the parts of the page, such as the date paragraph and the list of things to bring.\nCSS controls their appearance, such as how far apart they sit and how they fit on a narrow screen.\nJavaScript can add behavior where the browser has no built-in control for the job.\nA date, a list, and a link to that list are all things a browser can handle with HTML alone.\nStarting there gives you fewer places to look when something goes wrong.",[10,28,29],{},"We're going to build for a reader who has never been to the Cedar Room and might be looking up the entrance while carrying a small appliance.\nThat person can find the date and entrance without selecting a tab or closing a popup.\nA reader using the keyboard can follow a link to a heading that says what to bring.\nNeither path depends on a photo, a map widget, an account, or a countdown.\nIf the page is still useful after you turn off its styling, you have a good foundation for adding any of those things later.",[10,31,32,33,38,39,43],{},"A chat tool can return text for you to paste into files.\nIf you want the tool to open and edit those files itself, read ",[34,35,37],"a",{"href":36},"\u002Fbuild\u002Fwhat-is-an-ai-coding-agent","what an AI coding agent does",".\nIf you are still choosing how to work, ",[34,40,42],{"href":41},"\u002Fbuild\u002Fvibe-coding-tools","compare the leading vibe coding tools"," on a page this small before asking them to handle a whole site.",[14,45,47],{"id":46},"build-your-first-site-with-ai","Build: your first site with AI",[10,49,50,51,55],{},"Make a new folder called ",[52,53,54],"code",{},"cedar-room-sample"," and keep your other projects out of it.\nIf you use chat, leave the folder empty for now and save each file it returns in that folder.\nIf you use a coding agent, open only this folder and check each request to write files or run commands.\nThis page needs no accounts, keys, package installation, or permission to publish.\nIf you already use Git, you can commit the files once you have a working draft.\nOtherwise, save a separate copy of the working folder before you make the next change.",[10,57,58],{},"Write down what the visitor should be able to do before you decide what the page looks like.\nFor the example, the reader can find the date, hours, and entrance near the top, then jump to the supply list.\nThe event is fictional, so put a visible sample label on the page.\nFor a real event, confirm the facts with the organizer before sending a brief to the tool.\nIf all you have is a neighborhood name, leave the exact entrance out until you know it.\nAn invented street address makes a draft look finished at the exact point where it needs more work.",[10,60,61,62,66],{},"Give the AI the brief below or use it to check a draft you wrote yourself.\nFor an example of working inside a project folder from a terminal, see ",[34,63,65],{"href":64},"\u002Fbuild\u002Fclaude-code-tutorial","the Claude Code tutorial",".",[68,69,75],"pre",{"className":70,"code":72,"language":73,"meta":74},[71],"language-text","Draft a single page for the fictional Cedar Room repair cafe.\nMark it as a sample event in the visible page.\nThe drop-in is Sunday, May 16, 2027, 2 to 4 p.m. local time.\nUse the north entrance of the Cedar Room.\nAsk people to bring one broken household item and any matching parts they already have.\nShow the date, hours, and entrance just below the only main heading.\nAdd a link called \"See what to bring\" above the supply section.\nHave it jump to the \"What to bring\" heading, followed by a real list.\nUse only index.html and styles.css. No scripts, forms, packages, or remote assets.\nKeep text readable at 320 CSS pixels and leave a visible focus ring for keyboard users.\nUse the facts I supplied and do not add others.\nList what you created and how I can open the result locally. Do not publish it.\n","text","",[52,76,72],{"__ignoreMap":74},[10,78,79,80,83,84,87,88,91,92,66],{},"Keep the first result narrow enough to review in a few minutes.\nIf it comes back with a form or a dependency list, ask for the two requested files before discussing colors or layout.\nDon't paste a block of setup commands into your terminal just because the tool prefaced it with instructions for your operating system.\nYou can open a static HTML file directly from a file manager.\nIf you work in a plain text editor, confirm the files really end in ",[52,81,82],{},".html"," and ",[52,85,86],{},".css",", not ",[52,89,90],{},".html.txt"," or ",[52,93,94],{},".css.txt",[10,96,97],{},"Open the draft in a browser as soon as the files exist.\nLook for the event details first, not the design.\nCompare the words on screen with your notes about the event, including whether the start and finish times are both written down.\nIf the page has an extra fee, a claim about what can be repaired, or a rule about who can take part, remove it unless you have a source for it.\nThen click the link and confirm that it points to the supply heading on the same page.\nKeep the browser and editor open side by side if your screen has room.\nAfter every change, save the file and reload the page before deciding that the change helped.",[10,99,100],{},"One file is enough for a person to verify the words.\nWe separated the styles into a second file so you can open the markup without scrolling through a hundred lines of colors and sizes first.\nYou can later give another page the same look by using that same file.\nAvoid growing the project until you can make one edit to the current page without outside help.",[14,102,104],{"id":103},"read-what-the-ai-actually-wrote","Read: what the AI actually wrote",[10,106,107,108,111,112,115,116,119,120,123],{},"Find the title in your HTML file and compare it with the text in the browser tab.\nThen find the ",[52,109,110],{},"h1"," and compare it with the title on the page.\nThey can be related without being identical: if several tabs are open, the tab title needs to identify the page even when the heading is hidden behind them.\nLook for ",[52,113,114],{},"lang=\"en\""," on the ",[52,117,118],{},"html"," element so assistive tools can identify the language of the sample.\nThe code below is one small reference version of the HTML.\nIt will show the content without a stylesheet; add ",[52,121,122],{},"styles.css"," beside it to try the second example.",[68,125,129],{"className":126,"code":128,"language":118,"meta":74},[127],"language-html","\u003C!doctype html>\n\u003Chtml lang=\"en\">\n\u003Chead>\n  \u003Cmeta charset=\"utf-8\">\n  \u003Cmeta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n  \u003Ctitle>Sample event: Cedar Room repair cafe\u003C\u002Ftitle>\n  \u003Clink rel=\"stylesheet\" href=\"styles.css\">\n\u003C\u002Fhead>\n\u003Cbody>\n  \u003Cmain>\n    \u003Cp>Sample event\u003C\u002Fp>\n    \u003Ch1>Cedar Room repair cafe\u003C\u002Fh1>\n    \u003Cp>Sunday, May 16, 2027, from 2 to 4 p.m. local time.\u003C\u002Fp>\n    \u003Cp>North entrance of the Cedar Room.\u003C\u002Fp>\n    \u003Cp>\u003Ca href=\"#what-to-bring\">See what to bring\u003C\u002Fa>\u003C\u002Fp>\n    \u003Csection aria-labelledby=\"what-to-bring\">\n      \u003Ch2 id=\"what-to-bring\" tabindex=\"-1\">What to bring\u003C\u002Fh2>\n      \u003Cul>\n        \u003Cli>One broken household item\u003C\u002Fli>\n        \u003Cli>Any matching parts you already have\u003C\u002Fli>\n      \u003C\u002Ful>\n    \u003C\u002Fsection>\n  \u003C\u002Fmain>\n\u003C\u002Fbody>\n\u003C\u002Fhtml>\n",[52,130,128],{"__ignoreMap":74},[10,132,133,134,137,138,140,141,144,145,148,149,152,153,156],{},"Before reading the style sheet, trace the bring link in the HTML.\nThe address starts with ",[52,135,136],{},"#",", so the link points inside the current page.\nThe part after ",[52,139,136],{}," must match the destination heading's ",[52,142,143],{},"id"," exactly.\nThe heading has ",[52,146,147],{},"tabindex=\"-1\""," so it can take focus as a destination without adding an extra stop when someone presses Tab through the page.\nThe ",[52,150,151],{},"ul"," and its ",[52,154,155],{},"li"," elements give the supply items list structure even if the design later changes the bullet style.\nThe section's label is taken from the same heading, so there isn't a second copy of the heading text to keep up to date.",[10,158,159,160,163],{},"Now make one practice change: edit the entrance from north to east in your local copy and reload.\nIf the old direction still appears, make sure you're editing the same file that the browser opened.\nWhen you're done, restore the original wording so it matches the brief again.\nMake a second change on paper: write down what you'd need to update if you renamed the target ID to ",[52,161,162],{},"supplies",".\nFix the heading ID and each reference to it, not just the link a sighted visitor can see.\nThat's a useful way to read any generated markup that has a control and a destination.",[10,165,166],{},"For the style sheet, begin with a page width that stops expanding on a large screen and room for text to wrap on a small one.\nThe following rules are enough for this example.\nRead the selector at the start of each block as the part it applies to, then read the lines inside as the changes to that part.",[68,168,173],{"className":169,"code":171,"language":172,"meta":74},[170],"language-css","body {\n  margin: 0;\n  background: #fff;\n  color: #1b2622;\n  font: 1rem\u002F1.6 system-ui, sans-serif;\n}\n\nmain {\n  max-width: 40rem;\n  margin-inline: auto;\n  padding: clamp(1rem, 5vw, 3rem);\n}\n\na { color: #005a44; }\n\n:focus-visible {\n  outline: 3px solid #005a44;\n  outline-offset: 3px;\n}\n\nh2 { scroll-margin-block-start: 1rem; }\n","css",[52,174,171],{"__ignoreMap":74},[10,176,177,178,182],{},"If the AI added a different rule you can't explain, open the browser inspector and select the element it affects.\nToggle that rule in the inspector before making a permanent edit.\nIf nothing obvious changes, check whether the rule applies only at a different screen width or when a link has focus.\nKeep an unfamiliar rule when you can explain what problem it solves; discard it if it was only extra decoration for a component the draft doesn't use.\nFor help with the underlying elements, the ",[34,179,181],{"href":180},"\u002Fbuild","Build with AI hub"," has starting points for learning to review a page one change at a time.",[14,184,186],{"id":185},"check-validators-accessibility-performance","Check: validators, accessibility, performance",[10,188,189],{},"Run the saved HTML file through a conformance checker, such as the Nu HTML Checker.\nIf you can't share the draft with an outside service, use a checker you can run locally.\nCorrect the first error before tackling all the lines below it, because a broken start tag can change how the checker reads the rest of the document.\nReload and run the check again after editing the source.\nThe browser can repair some mistakes as it builds the page, so a preview that looks normal does not settle whether the file is valid.\nLikewise, validation cannot tell you whether the entrance is right or whether you made the words large enough to read.",[10,191,192,193,196],{},"Try the main task as if your pointer were out of reach.\nStart at a fresh page, press Tab, and look for the outline around \"See what to bring.\"\nPress Enter and check that the address gains ",[52,194,195],{},"#what-to-bring"," and the browser takes you to the named heading.\nThe whole example may fit in a tall browser window, so the absence of a big scroll does not mean the link failed.\nInspect the destination and focus, or repeat in a shorter window where the target begins below the fold.\nIf you later add a way back to the top, test that link independently from both input methods.",[10,198,199],{},"Use the browser's mobile preview to set the page near 320 CSS pixels wide.\nThen zoom the browser and see if the entrance and link stay readable or force you to pan sideways.\nIf a paragraph goes past the edge, look for a fixed width on its container, overly generous side padding, or text that has been told never to wrap.\nRemove the layout restriction that created the overflow instead of hiding everything past the edge.\nUse an actual phone too if you can: a desktop touch preview cannot tell you whether your thumb keeps catching another link or whether you can read the entrance in daylight.",[10,201,202],{},"Listen to the heading and link in a screen reader if one is available on your device.\nLook for a named main heading, a recognizable list, and a link that still makes sense when you hear it without the paragraph around it.\nYou can also inspect the accessibility tree, the browser's structured view of the controls and landmarks.\nThat view helps you find the name the screen reader should get, but it is not a substitute for listening and navigating with the real software.\nIf you haven't tried that path, note that gap instead of declaring the page accessible on the strength of a checker score.",[10,204,205],{},"Open the browser's Network panel and reload.\nFor a hosted copy of the reference example, you expect the document and its stylesheet, plus perhaps a browser request for a favicon if the browser looks for one.\nInvestigate any library, custom font, or embed you weren't expecting before you decide if it's worth keeping.\nA slow connection is a useful follow-up check for a hosted preview: see how much of the visit still works before optional media arrives.\nIf you later add a venue photo, make it only as large as readers need and reserve space with its width and height so the text below does not jump as it loads.\nGive the image a text alternative if it carries information readers need; keep the actual directions in text either way.",[10,207,208],{},"Record the results in the project folder.\nA useful note says what you tried and what happened, such as \"390px: the entrance line wraps, and the jump link lands on What to bring.\"\nIf you found a bug, record the width or input method that exposed it and repeat that same check after the fix.\nIt is easier to tell if an AI edit helped when you can show the original failure rather than describing a feeling about the page.",[14,210,212],{"id":211},"own-the-site-is-yours-now","Own: the site is yours now",[10,214,215],{},"Keep your HTML, your stylesheet, and enough instructions to reopen the project on another computer.\nWrite down which file is the start page, what information needs to be confirmed before a real date change, and where to upload the public copy if you decide to share it.\nFor this project a plain text note in your working folder is enough.\nIf you later use build tools, also record how to install dependencies and which output folder is safe to upload; a successful preview inside an editor is not a build instruction.",[10,217,218],{},"You can leave this exercise offline.\nIf you publish a real page, use a static host that can serve the files under an address you control or can replace, and keep your own copy of what you uploaded.\nPublish the intended website files only, not private notes, configuration files, or a project folder full of unrelated drafts.\nVerify what the host makes public before sending anybody the URL.\nOnce the preview is online, open it in a fresh tab where you are not signed into the editor or hosting dashboard.\nConfirm the document and stylesheet load, then try the entrance and supply-list task from the public URL.",[10,220,221],{},"Give future changes a date as well as a filename.\nFor example, keep a short note that says the hours came from the organizer's latest schedule and that they need to be checked again before the next event.\nWhen an event is over, change the visible page so it no longer invites someone to turn up.\nIf you keep last year's page for reference, label it as past and point readers to the current schedule once there is one.",[10,223,224],{},"Keep the last version that passed the checks someplace separate from the live files.\nWhen someone reports a problem, first reproduce it on the public URL to rule out an old file on your own computer.\nIf you need to back out a bad update, put the last good files back and open the public URL again; restoring a file on disk is only half the job.\nIf you have handed the page to someone else, give them the instructions and a way to update or retrieve those same files.\nAn AI chat transcript can be useful background, but someone should be able to make the ordinary updates with the project alone.",[10,226,227],{},"Try the handoff before calling the exercise done.\nClose your AI tool, copy the folder, and open the copy from your file manager.\nChange the event hours in the new copy and check that the link still works at a phone width.\nIf the page relies on a preview or an account you didn't know you were using, this is when you find out.\nIf it works, write down the steps you took so the next person can repeat them without starting a new chat or asking how the page was generated.",{"title":74,"searchDepth":229,"depth":229,"links":230},2,[231,232,233,234,235],{"id":16,"depth":229,"text":17},{"id":46,"depth":229,"text":47},{"id":103,"depth":229,"text":104},{"id":185,"depth":229,"text":186},{"id":211,"depth":229,"text":212},"The HTML For All thesis in one guide: build your first website with AI tools, then learn to read, check, and own what they produce.","md",[46,103,185,211],{},true,"\u002Fbuild\u002Fbuild-a-website-with-ai","build a website with ai","2026-12-01T06:24:13Z",[245,246,247],"Article","BreadcrumbList","HowTo",{"title":5,"description":236},"draft","build\u002Fbuild-a-website-with-ai",null,"2","_3Jcm-Pmtxzjpx3O3Yc3Blwk8P0joKeAYP4f4POBPgo",1796185435708,"a1d53563-3a78-4678-8315-e5bd6a5bd80c"]