I investigated the automatic continuation setting (askUserQuestionTimeout) for waiting for Claude Code responses

I investigated the automatic continuation setting (askUserQuestionTimeout) for waiting for Claude Code responses

Claude Code had an issue where work stopped when a question dialog appeared during absence. This article introduces the askUserQuestionTimeout setting for auto-continuing after a set wait time.
2026.07.05

This page has been translated by machine translation. View original

Hello, I'm Tsukuboshi (tsukuboshi0755)!

Claude Code has a mechanism called AskUserQuestion, where the model asks the user multiple-choice questions during work.

While convenient, if you step away while a question is displayed, the agent's work keeps stopping until you answer.

So in this article, I'll introduce the askUserQuestionTimeout setting that allows you to automatically continue after a certain period of waiting for an answer!

What is askUserQuestionTimeout

askUserQuestionTimeout is a configuration key that can be specified in Claude Code's settings.json.
When the AskUserQuestion dialog remains idle for the specified duration without any interaction, it automatically proceeds by adopting the option that was pre-selected at that point.

The main specifications are as follows.

Item Content
Setting key askUserQuestionTimeout
Default value "never" (waits indefinitely for an answer)
Specifiable values Time strings like "60s", "5m", "10m", or "never"
Setting scope User settings (~/.claude/settings.json) only
Required version Claude Code v2.1.200 or later

The default is "never", so if nothing is set, it will continue to wait for an answer as before.

How to Configure

Add it as a top-level key to the user settings ~/.claude/settings.json.

{
  "askUserQuestionTimeout": "5m"
}

In the above example, if the question dialog remains idle for 5 minutes, it will automatically continue with the pre-selected option!

Notes

Only valid in user scope

According to the official documentation, this setting is exclusively for user scope.
Please note that it will not be read even if written in project settings (.claude/settings.json) or local settings (.claude/settings.local.json).
Rather than enforcing it on the team's repository side, it is positioned as an item that each user sets according to their own preferences.

The option that auto-continues is the pre-selected one

The option adopted on timeout is the one currently selected in the dialog at that point.
Since there is a possibility of proceeding with an unintended choice, when entrusting long-running automated work, we recommend differentiating usage based on the work content, such as setting a longer timeout value (e.g., "10m"), or keeping it as "never" for tasks where important decisions are expected.

References

https://code.claude.com/docs/en/settings.md

In Closing

This time, I introduced the askUserQuestionTimeout setting that allows you to automatically continue after a certain period of waiting for an AskUserQuestion answer.

When using Claude Code for long autonomous work sessions, hasn't everyone had the experience of coming back to find it stopped with a question while you were away?
By configuring askUserQuestionTimeout, you can prevent work from stopping indefinitely while waiting for an answer, making it a setting that pairs well with workflows where you hand off work to the agent and leave it unattended.

On the other hand, as you can tell from the default being "never", answering questions is originally an important point that reflects the user's judgment, so it seems best not to rely too heavily on auto-continuation and to differentiate the timeout value according to the nature of the task.

I hope this is helpful to someone!

That's all from Tsukuboshi (tsukuboshi0755)!


Claudeならクラスメソッドにお任せください

クラスメソッドは、Anthropic社とリセラー契約を締結しています。各種製品ガイドから、業種別の活用法、フェーズごとのお悩み解決などサービス支援ページにまとめております。まずはご覧いただき、お気軽にご相談ください。

サービス詳細を見る

Share this article

AI白書