# logs View logs for a workspace ## Usage ```console coder logs [flags] ``` ## Description ```console View logs for a workspace ``` ## Options ### -n, --build-number | | | |---------|------------------| | Type | int | | Default | 0 | Only show logs for a specific build number. Defaults to 0, which maps to the most recent build (build numbers start at 1). Negative values are treated as offsets—for example, -1 refers to the previous build. ### -f, --follow | | | |---------|--------------------| | Type | bool | | Default | false | Follow logs as they are emitted.