# .well-known/caldav warning

**URL:** <https://help.nextcloud.com/t/well-known-caldav-warning/77429>\
**Category:** 📦 Appliances (Docker, Snappy, VM, NCP, AIO)\
**Tags:** ncp\
**Created:** [April 11, 2020, 1:08pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429 "2020-04-11T13:08:37Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![GambaJo](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gambajo/32/19473_2.png) [@GambaJo](https://help.nextcloud.com/u/GambaJo)\
**Post date:** [April 11, 2020, 1:08pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/1 "2020-04-11T13:08:37Z")

</div>

Nextcloud version _(eg, 12.0.2)_: 18.0.3  
Operating system and version _(eg, Ubuntu 17.04)_: Raspbian GNU/Linux 10 (buster)  
Apache or nginx version _(eg, Apache 2.4.25)_: Apache/2.4.38 (Raspbian)  
PHP version _(eg, 7.1)_: PHP 7.3.14-1~deb10u1 (cli)

The issue you are facing:

- Your web server is not properly set up to resolve “/.well-known/caldav”. \_
- Your web server is not properly set up to resolve “/.well-known/carddav”.

Is this the first time you’ve seen this error? _(Y/N)_: N

Steps to replicate it:

1. Call overview in NCP’s Settings

The output of your config.php file in `/path/to/nextcloud` (make sure you remove any identifiable information!):

```auto
<?php
$CONFIG = array (
  'passwordsalt' => 'XXX',
  'secret' => 'XXX',
  'trusted_domains' =>
  array (
    0 => 'localhost',
    11 => '2a02:908:212:ed40:8618:a611:c43f:8d2c',
    1 => '192.168.0.87',
    5 => 'nextcloudpi.local',
    7 => 'nextcloudpi',
    8 => 'nextcloudpi.lan',
    20 => 'example.com',
    21 => '192.168.0.87',
  ),
  'datadirectory' => '/media/ssd_nextcloud/nextcloud/ncdata/',
  'dbtype' => 'mysql',
  'version' => '18.0.3.0',
  'overwrite.cli.url' => 'http://localhost',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'ncadmin',
  'dbpassword' => 'XXX',
  'installed' => true,
  'instanceid' => 'oc6cnssj6shs',
  'memcache.local' => '\\OC\\Memcache\\Redis',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'redis' =>
  array (
    'host' => '/var/run/redis/redis.sock',
    'port' => 0,
    'timeout' => 0.0,
	'overwrite.cli.url' => 'http://localhost',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'XXX',
  'dbpassword' => 'XXX',
  'installed' => true,
  'instanceid' => 'oc6cnssj6shs',
  'memcache.local' => '\\OC\\Memcache\\Redis',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'redis' => array ( 'host' => '/var/run/redis/redis.sock',
    'port' => 0,
    'timeout' => 0.0,
    'password' => 'XXX',
  ),
  'mail_smtpmode' => 'smtp',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_from_address' => 'XXX',
  'mail_domain' => 'XXX',
  'preview_max_x' => '2048',
  'preview_max_y' => '2048',
  'jpeg_quality' => '60',
  'overwriteprotocol' => 'https',
  'maintenance' => false,
  'tempdirectory' => '/media/ssd_nextcloud/nextcloud/ncdata/tmp',
  'logfile' => '/media/ssd_nextcloud/nextcloud/ncdata/nextcloud.log',
  'mail_sendmailmode' => 'smtp',
  'mail_smtpsecure' => 'tls',
  'mail_smtphost' => 'XXX',
  'mail_smtpport' => '587',
  'mail_smtpauth' => 1,
  'mail_smtpname' => 'XXX',
  'mail_smtppassword' => 'XXX',
  'updater.release.channel' => 'stable',
  'theme' => '',
  'loglevel' => 2,
);

```

My Nextcloud instance is installed unter /var/www/nextcloud. Also SSL encryption via letsencrypt and certbot.  
I found this hints ([https://docs.nextcloud.com/server/18/admin\_manual/issues/general\_troubleshooting.html#service-discovery](https://docs.nextcloud.com/server/18/admin_manual/issues/general_troubleshooting.html#service-discovery)) but I don’t know which .htaccess file I should edit (there are several in the folders like /var/www or /var/www/html or /var/www/nextcloud).  
I also found some solutions from other people to edit some conf files to redirect (000-default.conf, default-ssl.conf, nextcloud-ssl.conf) of apache, but all this did’t help.

I’m really confused.

---

<div class="post-metadata">

**Author:** ![KarlF12](https://help.nextcloud.com/user_avatar/help.nextcloud.com/karlf12/32/46873_2.png) [@KarlF12](https://help.nextcloud.com/u/KarlF12)\
**Post date:** [April 11, 2020, 1:49pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/2 "2020-04-11T13:49:43Z")

</div>

The rewrite rules go in the Apache site config.

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 11, 2020, 4:34pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/3 "2020-04-11T16:34:42Z")

</div>

Hello,  
The .htaccess is in /var/www/nextcloud. There is only one .htaccess in /var/www/nextcloud.  
Read this to understand .htaccess  
[https://httpd.apache.org/docs/2.4/en/howto/htaccess.html](https://httpd.apache.org/docs/2.4/en/howto/htaccess.html)

When you edit .htaccess, dont forget to reload configuration with :  
sudo systemctl reload apache2  
or  
(sudo systemctl restart apache2)

---

<div class="post-metadata">

**Author:** ![GambaJo](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gambajo/32/19473_2.png) [@GambaJo](https://help.nextcloud.com/u/GambaJo)\
**Post date:** [April 14, 2020, 10:22am UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/4 "2020-04-14T10:22:40Z")

</div>

Ok, I edited /var/www/nextcloud/.htaccess:

```auto
<IfModule mod_rewrite.c>
  RewriteEngine on
  RewriteCond %{HTTP_USER_AGENT} DavClnt
  RewriteRule ^$ /remote.php/webdav/ [L,R=302]
  RewriteRule .* - [env=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
  RewriteRule ^\.well-known/host-meta /nextcloud/public.php?service=host-meta [QSA,L]
  RewriteRule ^\.well-known/host-meta\.json /nextcloud/public.php?service=host-meta-json [QSA,L]
  RewriteRule ^\.well-known/webfinger /nextcloud/public.php?service=webfinger [QSA,L]
  RewriteRule ^\.well-known/nodeinfo /nextcloud/public.php?service=nodeinfo [QSA,L]
  RewriteRule ^\.well-known/carddav /nextcloud/remote.php/dav/ [R=301,L]
  RewriteRule ^\.well-known/caldav /nextcloud/remote.php/dav/ [R=301,L]
  RewriteRule ^remote/(.*) remote.php [QSA,L]
  RewriteRule ^(?:build|tests|config|lib|3rdparty|templates)/.* - [R=404,L]
  RewriteCond %{REQUEST_URI} !^/\.well-known/(acme-challenge|pki-validation)/.*
  RewriteRule ^(?:\.|autotest|occ|issue|indie|db_|console).* - [R=404,L]
</IfModule>

```

But the warning is still there.

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 14, 2020, 1:10pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/5 "2020-04-14T13:10:09Z")

</div>

I read the doc and im not sure to understand :

According to me, it means that :  
-If your url is http(s)://mydomain/nextcloud, so you need to edit the .htaccess in /var/www with RewriteRule ^.well-known/carddav /nextcloud/remote.php/dav/ [R=301,L]

```
 -if your url is http(s)://mydomain, you need to edit the .htaccess in /var/www/nextcloud with RewriteRule ^\.well-known/carddav /remote.php/dav/ [R=301,L]

```

Dont forget to restart apache2 !

Documentation :  
"  
If Nextcloud is running at the document root of your Web server the correct URL is:

`https://example.com/remote.php/dav` for CardDAV and CalDAV and `https://example.com/public.php?service=webfinger`

and if running in a subfolder like `nextcloud` :

`https://example.com/nextcloud/remote.php/dav` `https://example.com/nextcloud/public.php?service=webfinger`

For the first case the `.htaccess` file shipped with Nextcloud should do this work for you when you’re running Apache. You need to make sure that your Web server is using this file. Additionally, you need the mod\_rewrite Apache module installed to process these redirects.

If your Nextcloud instance is installed in a subfolder called `nextcloud` and you’re running Apache create or edit the `.htaccess` file within the document root of your Web server and add the following lines:"  
"

The nginx doc is clearer : [https://docs.nextcloud.com/server/latest/admin\_manual/installation/nginx.html](https://docs.nextcloud.com/server/latest/admin_manual/installation/nginx.html) and confirm what I said

---

<div class="post-metadata">

**Author:** ![GambaJo](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gambajo/32/19473_2.png) [@GambaJo](https://help.nextcloud.com/u/GambaJo)\
**Post date:** [April 14, 2020, 3:38pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/6 "2020-04-14T15:38:27Z")

</div>

Installation: /var/www/nextcloud  
URL: [https://myDomain](https://myDomain) (without nextcloud or whatever)

So witch .htaccess should I edit? And what should I add or remove in this file?  
Because I edited /var/www/nextcloud/.htaccess, but it doesn’t matter if I add “/nextcloud/…” or not, I always have the problem.

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 14, 2020, 3:50pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/7 "2020-04-14T15:50:33Z")

</div>

According to the doc, you need to edit the .htaccess in /var/www/nextcloud/.htaccess  
And without “/nextcloud/”

RewriteRule ^.well-known/carddav /remote.php/dav/ [R=301,L]  
RewriteRule ^.well-known/caldav /remote.php/dav/ [R=301,L]

Then : **sudo systemctl restart apache2**

If it doesn’t work, you can try to edit the main file configuration of your nextcloud, in /etc/apache2/sites-available/??? (nextcloud, nextcloud.conf, 000-default…). It comes down to the same, Apache first read your main configuration and then the .htaccess. So, you can just edit the main config if you want to be sure it works

---

<div class="post-metadata">

**Author:** ![GambaJo](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gambajo/32/19473_2.png) [@GambaJo](https://help.nextcloud.com/u/GambaJo)\
**Post date:** [April 20, 2020, 9:06am UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/8 "2020-04-20T09:06:11Z")

</div>

> [@bastien](#):
>
> **sudo systemctl restart apache2**

Ok, I edited my /var/www/nextcloud/.htaccess and /var/www/.htaccess and /etc/apache2/sites-available/000-default.conf like this:

```auto
RewriteRule ^\.well-known/carddav /remote.php/dav/ [R=301,L]
RewriteRule ^\.well-known/caldav /remote.php/dav/ [R=301,L]

```

and restarted the web server, but the problems are still there.

In /etc/apache2/sites-available/ there are this files:

- 000-default.conf
- default-ssl.conf
- ncp-activation.conf
- ncp.conf
- nextcloud-ssl.conf

000-default.conf is the only one with a part.

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 20, 2020, 10:57am UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/9 "2020-04-20T10:57:23Z")

</div>

Hello,

1. Can you list the content of /etc/apache2/sites-enabled ant post contents of files in /etc/apache2/sites-enabled

2. Check your syntax with ` sudo apachectl -t`

Good luck 😉

---

<div class="post-metadata">

**Author:** ![selenite](https://help.nextcloud.com/letter_avatar/selenite/32/5_5575768a8748004e209b776fc1b2916d.png) [@selenite](https://help.nextcloud.com/u/selenite)\
**Post date:** [April 20, 2020, 1:14pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/10 "2020-04-20T13:14:30Z")

</div>

Hello,

I have the same problem. I did the same on my .htaccess and still have the notification.

I don’t know if it helps, but the documentation tells this, too :

"Now change the URL in the client settings to just use:

```auto
https://example.com

```

instead of e.g.

`https://example.com/nextcloud/remote.php/dav/principals/username`."

But it is impossible, in the client you can just copy the url, not change it !

![contacts](https://help.nextcloud.com/uploads/default/original/3X/9/4/948adc8e628e0b3555d8cbf66dc6f2dbfc69b955.jpeg)

(Sorry if this message is not helpful, I am a beginner. For information my nextcloud is built on a shared server and I work on it on windows via ftp.)

---

<div class="post-metadata">

**Author:** ![KarlF12](https://help.nextcloud.com/user_avatar/help.nextcloud.com/karlf12/32/46873_2.png) [@KarlF12](https://help.nextcloud.com/u/KarlF12)\
**Post date:** [April 20, 2020, 1:23pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/11 "2020-04-20T13:23:14Z")

</div>

This is supposed to be done in your Apache site config… not .htaccess unless you are not the server admin.

```
<VirtualHost *:443>
  ServerName cloud.domain.name
  ErrorLog ${APACHE_LOG_DIR}/nextcloud-error.log
  CustomLog ${APACHE_LOG_DIR}/nextcloud-access.log combined
  SSLEngine On
  ProxyPreserveHost On
  ProxyPass / http://127.0.0.1:8080/
  ProxyPassReverse / http://127.0.0.1:8080/
  # Header always set Strict-Transport-Security "max-age=15552000; includeSubDomains"
  RewriteEngine On
  RewriteRule ^/\.well-known/carddav https://%{SERVER_NAME}/remote.php/dav/ [R=301,L]
  RewriteRule ^/\.well-known/caldav https://%{SERVER_NAME}/remote.php/dav/ [R=301,L]
  SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem
  SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key
</VirtualHost>
```

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 20, 2020, 1:52pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/12 "2020-04-20T13:52:00Z")

</div>

Actually, the documentation of NextCloud says to edit the .htaccess but the documentation of apache advises to edit your config file rather than a .htaccess. It’s not really important… In both cases, it’s supposed to work.  
[https://docs.nextcloud.com/server/latest/admin\_manual/issues/general\_troubleshooting.html#service-discovery](https://docs.nextcloud.com/server/latest/admin_manual/issues/general_troubleshooting.html#service-discovery)  
[https://httpd.apache.org/docs/2.2/en/howto/htaccess.html](https://httpd.apache.org/docs/2.2/en/howto/htaccess.html)

---

<div class="post-metadata">

**Author:** ![GambaJo](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gambajo/32/19473_2.png) [@GambaJo](https://help.nextcloud.com/u/GambaJo)\
**Post date:** [April 21, 2020, 9:46am UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/13 "2020-04-21T09:46:36Z")

</div>

> [@bastien](#):
>
> Can you list the content of /etc/apache2/sites-enabled ant post contents of files in /etc/apache2/sites-enabled

- 000-default.conf
- ncp.conf
- nextcloud.conf
- nextcloud-ssl.conf

> [@bastien](#):
>
> Check your syntax with ` sudo apachectl -t`

Syntax OK

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 21, 2020, 2:23pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/14 "2020-04-21T14:23:03Z")

</div>

Hey,  
So you have to edit your nextcloud config. It can be nextcloud.conf or nextcloud-ssl.conf. I think that its nextcloud-ssl.conf.  
To be sure, add Rewrite Rule in sites-available/000-default.conf, sites-available/ncp.conf, sites-available/ncp.conf, sites-available/ncp.conf. And restart apache.

---

<div class="post-metadata">

**Author:** ![GambaJo](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gambajo/32/19473_2.png) [@GambaJo](https://help.nextcloud.com/u/GambaJo)\
**Post date:** [April 22, 2020, 10:30am UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/15 "2020-04-22T10:30:00Z")

</div>

> [@bastien](#):
>
> RewriteRule ^.well-known/carddav /remote.php/dav/ [R=301,L]  
> RewriteRule ^.well-known/caldav /remote.php/dav/ [R=301,L]
> 
> Then : **sudo systemctl restart apache2**

Ok, I edited the files.  
000-default.conf

```auto
<VirtualHost _default_:80>
  DocumentRoot /var/www/nextcloud
  <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteRule ^\.well-known/carddav /remote.php/dav/ [R=301,L]
    RewriteRule ^\.well-known/caldav /remote.php/dav/ [R=301,L]
    RewriteCond %{HTTPS} !=on
    RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
  </IfModule>
</VirtualHost>

```

ncp.conf

```auto
Listen 4443
<VirtualHost _default_:4443>
  DocumentRoot /var/www/ncp-web
  SSLEngine on
  SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem
  SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key

  # 2 days to avoid very big backups requests to timeout
  TimeOut 172800

  <IfModule mod_authnz_external.c>
    DefineExternalAuth pwauth pipe /usr/sbin/pwauth
  </IfModule>

  <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteRule ^\.well-known/carddav /remote.php/dav/ [R=301,L]
    RewriteRule ^\.well-known/caldav /remote.php/dav/ [R=301,L]
    RewriteCond %{HTTPS} !=on
    RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
  </IfModule>

</VirtualHost>
<Directory /var/www/ncp-web/>

  AuthType Basic
  AuthName "ncp-web login"
  AuthBasicProvider external
  AuthExternal pwauth

  SetEnvIf Request_URI "^" noauth
  SetEnvIf Request_URI "^index\.php$" !noauth
  SetEnvIf Request_URI "^/$" !noauth
  SetEnvIf Request_URI "^/wizard/index.php$" !noauth
  SetEnvIf Request_URI "^/wizard/$" !noauth

  <RequireAll>

   <RequireAny>
      Require host localhost
      Require local
      Require ip 192.168
      Require ip 172
      Require ip 10
      Require ip fe80::/10
      Require ip fd00::/8
   </RequireAny>

   <RequireAny>
      Require env noauth
      Require user ncp
   </RequireAny>

  </RequireAll>

</Directory>

```

nextcloud-ssl.conf

```auto
<VirtualHost *:443>
        ServerAdmin gambajo@posteo.de
        ServerName ortmann-media.eu
        DocumentRoot /var/www/nextcloud
        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined
        SSLEngine on
        SSLCertificateFile /etc/letsencrypt/live/ortmann-media.eu-0001/fullchain.pem
        SSLCertificateKeyFile /etc/letsencrypt/live/ortmann-media.eu-0001/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf

  <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteRule ^\.well-known/carddav /remote.php/dav/ [R=301,L]
    RewriteRule ^\.well-known/caldav /remote.php/dav/ [R=301,L]
    RewriteCond %{HTTPS} !=on
    RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
  </IfModule>
</VirtualHost>

```

Problem is still there. 😥

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 22, 2020, 11:05am UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/16 "2020-04-22T11:05:15Z")

</div>

Your right configuration is nextcloud-ssl.conf. Its useless to edit ncp.conf and 000-default.conf. Can I see nextcloud.conf configuration ?  
Did you restart apache ? (sudo systemctl restart apache\*)

Add this line and restart apache.

```
<IfModule mod_rewrite.c>
  RewriteEngine on
  RewriteRule ^\.well-known/host-meta /public.php?service=host-meta [QSA,L]
  RewriteRule ^\.well-known/host-meta\.json /public.php?service=host-meta-json [QSA,L]
  RewriteRule ^\.well-known/webfinger /public.php?service=webfinger [QSA,L]
  RewriteRule ^\.well-known/carddav /remote.php/dav/ [R=301,L]
  RewriteRule ^\.well-known/caldav /remote.php/dav/ [R=301,L]
</IfModule>
```

---

<div class="post-metadata">

**Author:** ![GambaJo](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gambajo/32/19473_2.png) [@GambaJo](https://help.nextcloud.com/u/GambaJo)\
**Post date:** [April 22, 2020, 12:04pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/17 "2020-04-22T12:04:03Z")

</div>

> [@bastien](#):
>
> Add this line and restart apache.

My nextcloud-ssl.conf now:

```auto
<VirtualHost *:443>
        ServerAdmin gambajo@posteo.de
        ServerName ortmann-media.eu
        DocumentRoot /var/www/nextcloud
        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined
        SSLEngine on
        SSLCertificateFile /etc/letsencrypt/live/ortmann-media.eu-0001/fullchain.pem
        SSLCertificateKeyFile /etc/letsencrypt/live/ortmann-media.eu-0001/privkey.pem
Include /etc/letsencrypt/options-ssl-apache.conf
  <IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteRule ^\.well-known/host-meta /public.php?service=host-meta [QSA,L]
    RewriteRule ^\.well-known/host-meta\.json /public.php?service=host-meta-json [QSA,L]
    RewriteRule ^\.well-known/webfinger /public.php?service=webfinger [QSA,L]
    RewriteRule ^\.well-known/carddav /remote.php/dav/ [R=301,L]
    RewriteRule ^\.well-known/caldav /remote.php/dav/ [R=301,L]
  </IfModule>
</VirtualHost>

```

> [@bastien](#):
>
> Can I see nextcloud.conf configuration ?

There is no such file.

> [@bastien](#):
>
> Did you restart apache ? (sudo systemctl restart apache\*)

Yes, sometimes even the whole Pi.

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 22, 2020, 12:40pm UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/18 "2020-04-22T12:40:59Z")

</div>

> [@GambaJo](#):
>
> - 000-default.conf
> - ncp.conf
> - nextcloud.conf
> - nextcloud-ssl.conf

In /etc/apache2/sites-enabled ?

---

<div class="post-metadata">

**Author:** ![GambaJo](https://help.nextcloud.com/user_avatar/help.nextcloud.com/gambajo/32/19473_2.png) [@GambaJo](https://help.nextcloud.com/u/GambaJo)\
**Post date:** [April 23, 2020, 10:07am UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/19 "2020-04-23T10:07:53Z")

</div>

> [@bastien](#):
>
> In /etc/apache2/sites-enabled ?

- @000default.conf
- @ncp.conf
- @nextcloud-ssl.conf
- !nextcloud.conf (file is empty/new file)

---

<div class="post-metadata">

**Author:** ![bastien](https://help.nextcloud.com/letter_avatar/bastien/32/5_5575768a8748004e209b776fc1b2916d.png) [@bastien](https://help.nextcloud.com/u/bastien)\
**Post date:** [April 24, 2020, 10:52am UTC](https://help.nextcloud.com/t/well-known-caldav-warning/77429/20 "2020-04-24T10:52:03Z")

</div>

Hey,  
I’m sorry for responding so late. nextcloud.conf is useless too.  
I dont know why but your Apache config disables rewrite rule. Be sure that rewrite rule are enabled :

```auto
sudo a2enmod rewrite
sudo systemctl restart apache2

```

And remove rewrite rule that you have created in the .htaccess

[Next page](https://help.nextcloud.com/t/well-known-caldav-warning/77429.md?page=2)
