400 'Instructions are not valid

Resolved 💬 5 comments Opened Sep 5, 2025 by mattsu2020 Closed Sep 5, 2025
💡 Likely answer: A maintainer (mattsu2020, contributor) responded on this thread — see the highlighted reply below.

What version of Codex is running?

https://github.com/openai/codex/commit/3f40fbc0a886ef54f494a1ff5963971bc42c036a

Which model were you using?

gpt-5

What platform is your computer?

Darwin 24.6.0 arm64 arm

What steps can reproduce the bug?

When I enter “hello,” the following error appears.
400 'Instructions are not valid'

What is the expected behavior?

Hello, and a response comes from ChatGPT.

What do you see instead?

ChatGPT exhibits behavior where it only accepts “authorized system prompts (instructions)”, and was being blocked by one of the following:
It was sending “instructions differing from the default” via config overrides (experimental_instructions_file/base_instructions).
During retries, even if the authentication mode changed, it did not regenerate the instructions and instead resubmitted “the previous ones (content flagged as invalid)”.

Additional information

This occurs when using ChatGPT without an API key.

View original on GitHub ↗

4 Comments

mattsu2020 contributor · 11 months ago
@mattsu2020 You must use this prompt only in the prompt.md so it will not return error fdda6a4

The same error occurs. It appears when authenticating with ChatGPT.

pakrym-oai contributor · 11 months ago

Sign In With ChaGPT doesn't support custom instructions. You can use custom instruction when authenticating with an API key.

3rd · 11 months ago

This happens for users who did not change the instructions. Nuking ~/.codex and launching codex built on master still hits this issue.
Please re-open @pakrym-oai

Edit: 6b83c1c3f3dacf6da342706098f1cb04335e8217 working commit

mattsu2020 contributor · 11 months ago

The original bug has been fixed in this commit.

https://github.com/openai/codex/pull/3212/files

Showing cached comments. Read the full discussion on GitHub ↗