How can i change the command-timeout?

I use appium 1.0 for windows.
I run the appium.exe,but I found I can not change the command-timeout.
Sorry,I can not install appium from the code.I can only use the offline version.
I try to run the following command:
c:\appium --command-timeout 120
But I run my script, I found the command-timeout is still 60s.
How can I change it?
Thanks very much!~

You need to set that in desired capability

I use the appium.exe version.
Today I update to version,but I still can not find the parameter “new command-timeout”.
How to solve it?

Go to Developer Settings on appium.exe, check Custom Server Flags checkbox and give server argument --command-timeout <‘Value’>


Navigate to the following directory in your appium installation

Open up the appium.js file and edit the following parameters.

  this.defCommandTimeoutMs = this.args.defaultCommandTimeout;
  this.commandTimeoutMs = this.defCommandTimeoutMs;

as follows

  this.defCommandTimeoutMs = this.args.defaultCommandTimeout * 5000;
  this.commandTimeoutMs = this.defCommandTimeoutMs * 5;

this will be enough to run the tests.



The problem has sloved.
Thanks all!~

I have the same problem. But it works absolutely fine with above solution.
Thanks a million, Ram.

I have the same issue timeout is 60 second, when I tried to change the time in appium.js, appium.js is not allowing to save the updated file, pops a error message as permission denied. However I have administrator privilege still same error so tried with admin login also in vain got same error.

please can anyone help me to address this issue?

For the newer versions of appium the command timeout need to be sent via capability. For example in java:

        capabilities.setCapability("newCommandTimeout", "45000");```

Thanks a lot @JoseCanavire I have also the same issue Now it works fine with the above solution.

Now appium has the ability to disable command timeout. Setting up 0 for newCommandTimeout will done the job. Either we can setup a long time or disable it.

DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.setCapability("newCommandTimeout", 0);

Refer PR: