Auth Error: No Code Return By Remote Server (OneDrive)

What is the problem you are having with rclone?

I have followed the rclone documention for creating client id & secret for personal onedrive account. (Microsoft OneDrive)
but still i am facing No code returned by remote server error.

Error: config failed to refresh token: Error: Auth Error
Code: ""
Description: No code returned by remote server

If I try using rclone default client id & secret, everything works fine!!

Run the command 'rclone version' and share the full output of the command.

rclone 1.63.0-termux

  • os/version: unknown
  • os/kernel: 4.19.157-perf-g1a6087bc0325-dirty (aarch64)
  • os/type: android
  • os/arch: arm64 (ARMv8 compatible)
  • go/version: go1.20.5
  • go/linking: dynamic
  • go/tags: noselfupdate

Which cloud storage system are you using? (eg Google Drive)


The rclone config contents with secrets removed.

type = onedrive
client_id = xxxxxxxxxx
client_secret = xxxxxxxxxx

When exactly you see this error?

When I am trying to authenticate with onedrive for the first time with my own client id & secret.

Use web browser to automatically authenticate rclone with remote?
 * Say Y if the machine running rclone has a web browser you can use
 * Say N if running rclone on a (remote) machine without web browser access
If not sure try Y. If Y failed, try N.

y) Yes (default)
n) No
y/n> y

It is not easy to troubleshoot this:( But 99% you made mistake when creating client_id/client_secret.

Delete them and carefully step by step create again. If all done correctly it works without any issues.

1 Like

So it works now?

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.