Skip to content

[FEATURE]:[v2] add no password flag for "opencode2 serve" #43039

Description

@Victozee26

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

V2 serve has auth by default has of V1 which doesn't

so my proposal is to add flags for no authentication or no authentication by default

add

--no-auth 

or

--no-password

for

opencode serve

Activity

  1. Victozee26 commented on Aug 17, 2026

    @Victozee26
    Author
  2. Zerquix18 commented on Sep 21, 2026

    @Zerquix18

    +1 really tired of trying to use the web UI and having to copy+paste the password. The browser won't remember it for some reason

  3. dekarl commented on Sep 21, 2026

    @dekarl

    It appears you can start with serve --service which does not print out a password, but still requires one (aka requests get a 401 status).
    #46270 contains a possible fix

  4. opencodejr commented on Oct 28, 2026

    @opencodejr

    Thanks for the suggestion, @Victozee26! You're asking for a way to run opencode serve in v2 without authentication, such as a --no-auth / --no-password flag, or no auth by default as in v1.

    In v2 the server always requires a password; this is intentional. If none is set, it generates a random one when it starts and prints it. Turning auth off has security implications, especially when the server is reachable from other machines, so maintainers will need to weigh it up. They'll consider the request.

    In the meantime, you can avoid a new random password on every run by setting a fixed one through an environment variable:

    OPENCODE_SERVER_PASSWORD=your-password opencode serve

    Clients then use that same password (username opencode for HTTP Basic auth).

  5. sxflynn commented on Oct 29, 2026

    @sxflynn

    Some of us run this service at home on a local network with no other users, so auth is pointless. And we use a VPN to connect to home in order to access it. Please give a way to disable auth.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions