Developers Documentation



301 error for file:

User Tools

Site Tools

Owncloud error - You are accessing the server from an untrusted domain

ownCloud gives you and error of “You are accessing the server from an untrusted domain. Please contact your administrator”. When you go to the webpage.


When you first access ownCloud it remembers the IP address or hostname initially used and for security purposes ignores ALL other requests using a different IP address or domain. To fix this error you will either need to replace the IP address used with a new one or add additional IP addresses and/or domains.


Access your server via command line or ssh. Backup up your current config with the following command:

cp /usr/share/owncloud/config/config.php /tmp/config-owncloud-old.php

Modify the config file with the following command (or use your favorite editor):

nano /usr/share/owncloud/config/config.php

In the section with trusted domains, change the IP address or domain name to include your domain. Initially, it may look similar to this:

'trusted_domains' =>
array (
0 => '',

You can change it to include your new address by changing the IP value or you can add additional addresses. For example:

'trusted_domains' =>
array (
0 => '',
1 => '',

Then save your changes to the file by pressing Ctrl+o and then press enter to accept the name of the file. Press Ctrl+x to exit nano.

Test it out.


content/en_us/kb_troubleshooting_you_are_accessing_the_server_from_an_untrusted_domain.txt · Last modified: 2015/02/17 10:25 (external edit)