Answer: Global commands live in ~/.config/opencode/commands/ and project commands live in .opencode/commands/. Status: Confirmed Entry: tool/opencode/settings/command-file-locations Revision: 1 Digest: sha256:77f9352a132dfd8e (changes whenever the content changes) Timeline: Created: 2026-11-13T03:56:32Z Last changed: 2026-11-13T03:56:32Z Last verified: 2026-11-20T13:45:31Z Next check: 2026-11-21T13:45:31Z Check interval: Daily Expected change: No fixed schedule Data: Field | Value | Source | As of global commands location | ~/.config/opencode/commands/ | [1] | 2026-11-20 project commands location | .opencode/commands/ | [1] | 2026-11-20 Sources: [1] opencode. "Commands | OpenCode". https://opencode.ai/docs/commands/ Role: primary. Accessed: 2026-11-20T13:45:31Z Quote: "Put global commands in ~/.config/opencode/commands/ and project commands in .opencode/commands/" (Supports: global commands location, project commands location) Snapshot SHA-256: ab163966231508aa8c5aa4acce2e91d6717fa361fbdc8d51624bd9f7706104f9 (captured 2026-11-13T03:56:32Z) Verification: Method: Automated extraction from [1] with deepseek-flash (JSON output, thinking disabled). Every value was checked by code to appear verbatim in a quoted passage of [1]. On this check the text of [1] was unchanged since 2026-11-13T03:56:32Z, so the values verified then were kept. Cross-check: not-available at 2026-11-20T13:45:31Z. No independent second source is configured for this entry Last successful check: 2026-11-20T13:45:31Z Last attempt: 2026-11-20T13:45:31Z Notes and limitations: Extracted automatically from a single official source (section "Markdown"). Related: https://latestn.com/tool/opencode/settings/compaction-buffer-setting How do I configure the compaction buffer setting in opencode? https://latestn.com/tool/opencode/settings/config-file-locations Where does opencode look for its config file and in what locations? https://latestn.com/tool/opencode/settings/config-variables How do I set environment variables or reference files in opencode config? https://latestn.com/tool/opencode/settings/cli-json-schema How do I add the JSON schema to opencode's cli.json for validation? https://latestn.com/tool/opencode/settings/cli-settings-file-location Where does opencode store its CLI settings file? https://latestn.com/tool/opencode/settings/cloudflare-customize-config How do I customize the opencode Cloudflare SDK configuration? https://latestn.com/tool/ All entries in AI tools Change log: Time | Event | Change | Source 2026-11-13T03:56:32Z | added | Entry created | — Changes for this entry as a feed: https://latestn.com/tool/opencode/settings/command-file-locations/latest Challenge this entry: Open challenges: None How: If a value here is wrong or out of date, send what is wrong and a link to evidence. Challenges are queued and checked against the evidence; they do not change the entry by themselves. If the entry changes as a result, the change log says so. Form: https://latestn.com/dispute/tool/opencode/settings/command-file-locations POST: https://latestn.com/dispute/tool/opencode/settings/command-file-locations with claim, evidence_url, and optionally field and contact (form-encoded or JSON) GET: https://latestn.com/dispute/tool/opencode/settings/command-file-locations?claim={what is wrong}&evidence_url={link} How to cite: LatestN. (2026). Where do global and project opencode commands live? Revision 1, last verified 2026-11-20T13:45:31Z. https://latestn.com/tool/opencode/settings/command-file-locations (accessed 2026-11-21T09:50:40Z). @misc{LatestN_tool_opencode_settings_command_file_locations_r1, title = {Where do global and project opencode commands live?}, author = {{LatestN}}, year = {2026}, howpublished = {\url{https://latestn.com/tool/opencode/settings/command-file-locations}}, note = {Revision 1; digest sha256:77f9352a132dfd8e; last verified 2026-11-20T13:45:31Z; accessed 2026-11-21T09:50:40Z} } Reuse: License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/) Attribution: Copying and adapting are allowed, including commercially, if you credit LatestN and link to the entry you used. Each entry ends with a ready-made citation. URL: https://latestn.com/tool/opencode/settings/command-file-locations