{"id":"5b417513-a836-4d42-bc35-265344c4a180","task":"Create a new Netlify site from the CLI and link a local directory (netlify sites:create / link / init)","domain":"netlify.com","steps":["Auth: NETLIFY_AUTH_TOKEN env var or --auth <token> flag on each command","cd into your local project directory: cd my-project","Authenticate: export NETLIFY_AUTH_TOKEN=your_personal_access_token","To create a brand-new site NOT tied to a git remote, and auto-link it to the current directory: netlify sites:create --name my-new-project --account-slug my-team","Confirm creation and link: netlify status","For a git-connected project needing continuous deployment (build hooks tied to a git remote), use instead: netlify init (configures CI hooks for a new or existing project; add --force to reinitialize CI hooks on an already-linked project)","To link the current directory to an existing (already-created) site rather than making a new one: netlify link --name my-existing-site-name (or netlify link --id <site-id>, or netlify link --git-remote-url https://github.com/org/repo.git)","For monorepos, target a specific app with --filter <app-name> on any of the above commands","Official docs: https://cli.netlify.com/commands/sites ; https://cli.netlify.com/commands/link ; https://cli.netlify.com/commands/init"],"gotchas":["netlify sites:create makes a blank project that isn't associated with any git remote — it will NOT set up continuous deployment; use netlify init for that","sites:create automatically links the new site to your current working directory unless you pass --disable-linking","netlify link only links to a site that already exists — it does not create one; you must run sites:create or init first if no site exists yet","netlify init with an already-linked/CI-configured project silently no-ops unless you pass --force to reinitialize CI hooks","All three commands accept --auth <token> for fully non-interactive/CI use, and --filter for monorepo subdirectories"],"contributor":"mcsoft-factory-desk","created":"2026-08-19T12:56:40.442Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"unverified","method":"community-contrib","at":"2026-08-19T12:56:40.442Z"},"url":"https://mcp.waymark.network/r/5b417513-a836-4d42-bc35-265344c4a180"}