# Well known caldav error in docker container

**URL:** <https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717>\
**Category:** ℹ️ Support\
**Tags:** nc32, docker, setup\_warning\_wellknown, webdav, setup\_warning\
**Created:** [October 26, 2025, 6:04pm UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717 "2025-10-26T18:04:32Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![Thor](https://help.nextcloud.com/user_avatar/help.nextcloud.com/thor/32/521_2.png) [@Thor](https://help.nextcloud.com/u/Thor)\
**Post date:** [October 26, 2025, 6:04pm UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/1 "2025-10-26T18:04:33Z")

</div>

The Basics

- Nextcloud Server version _(e.g., 29.x.x)_:
  - `32.0.1`

- Operating system and version _(e.g., Ubuntu 24.04)_:
  - `Docker/Linux`

- Web server and version _(e.g, Apache 2.4.25)_:
  - `Apache`

- Reverse proxy and version \_(e.g. nginx 1.27.2)
  - `nginx`

- PHP version _(e.g, 8.3)_:
  - `8.3.27`

- Is this the first time you’ve seen this error? (Yes / No):
  - `yes`

- When did this problem seem to first start?
  - `after installation`

- Installation method _(e.g. AlO, NCP, Bare Metal/Archive, etc.)_
  - `docker compose`

- Are you using CloudfIare, mod\_security, or similar? _(Yes / No)_
  - `no`

### Summary of the issue you are facing:

In the Admin section says well know caldav (only caldav, not carddav) can’t be properly resolved.  
I know there are many topics relatet to wellknown already but none provide a solution.  
What I don’t understand is, that it is the docker container the comes already with apache included and the rewrite url is set, also the htaccess is fine and I can access the url.

### Steps to replicate it (hint: details matter!):

1. Install latest docker image

2. overwrite.cli.url is set to the used domain

3. htaccess rewrite base is /

4. the htaccess says:  
`RewriteRule ^.well-known/carddav /remote.php/dav/ [R=301,L]`  
`RewriteRule ^.well-known/caldav /remote.php/dav/ [R=301,L]`

5. https:///.well-known/caldav redirects to https:///remote.php/dav/ and shows: This is the WebDAV interface. It can only be accessed by WebDAV clients such as the Nextcloud desktop sync client.

6. I can add my Calendar via webdav into Outlook.

### Log entries

#### logs seem fine, I couldn’t find any related error.

---

<div class="post-metadata">

**Author:** ![wwe](https://help.nextcloud.com/user_avatar/help.nextcloud.com/wwe/32/72963_2.png) [@wwe](https://help.nextcloud.com/u/wwe)\
**Post date:** [October 27, 2025, 1:43pm UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/2 "2025-10-27T13:43:07Z")

</div>

#setup_warning_wellknown might be misleading as most or all checks are running on the server since few versions. The server might have different network connectivity like DNS, firewall rules etc. this might explain why your system works but the check fails. Try running `curl https://cloud.mydomain.tld/.well-known/caldav` from inside of the app container, and if the error is not obvious review log (eventually increase logs level) and repeat until you see the problem.

---

<div class="post-metadata">

**Author:** ![Thor](https://help.nextcloud.com/user_avatar/help.nextcloud.com/thor/32/521_2.png) [@Thor](https://help.nextcloud.com/u/Thor)\
**Post date:** [October 30, 2025, 7:18pm UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/3 "2025-10-30T19:18:08Z")

</div>

The answer I get is 301 moved to [https://cloud.mydomain.tld/remote.php/dav/](https://cloud.mydomain.tld/remote.php/dav/)

Doing a curl for that gives:

> \<?xml version="1.0" encoding="utf-8"?\> 
> 
> \<d:error xmlns:d=“DAV:” xmlns:s=" [sabre/dav](http://sabredav.org/ns) "\>
> 
> \<s:exception\>Sabre\DAV\Exception\NotAuthenticated\</s:exception\>
> 
> \<s:message\>No public access to this resource., AppAPIAuth has not passed, This
> 
> request is not for a federated calendar, No ‘Authorization: Basic’ header found.
> 
> Either the client didn’t send one, or the server is misconfigured, No 'Authorizat
> 
> ion: Bearer’ header found. Either the client didn’t send one, or the server is mi
> 
> s-configured, No ‘Authorization: Basic’ header found. Either the client didn’t se
> 
> nd one, or the server is misconfigured\</s:message\>
> 
> \</d:error\>

---

<div class="post-metadata">

**Author:** ![wwe](https://help.nextcloud.com/user_avatar/help.nextcloud.com/wwe/32/72963_2.png) [@wwe](https://help.nextcloud.com/u/wwe)\
**Post date:** [October 30, 2025, 9:02pm UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/4 "2025-10-30T21:02:52Z")

</div>

when I access ` ../-well-known/caldav` I see a redirect message (everywhere outside and **inside** of container)

```auto
#docker compose exec app curl -I https://cloud.mydomain.tld/.well-known/caldav

HTTP/2 307 
alt-svc: h3=":443"; ma=2592000
location: https://cloud.mydomain.tld/remote.php/dav/

```

and yes this is exactly the output above when I access ` /remote.php/dav/` using curl… a browser shows a login form

---

<div class="post-metadata">

**Author:** ![Thor](https://help.nextcloud.com/user_avatar/help.nextcloud.com/thor/32/521_2.png) [@Thor](https://help.nextcloud.com/u/Thor)\
**Post date:** [October 31, 2025, 7:06am UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/5 "2025-10-31T07:06:10Z")

</div>

Sorry, but I don’t get how you post should help me.  
This is the full output I get:

```auto
docker exec nextcloud_app curl -I https://cloud.mydomain.tld/.well-known/caldav
  % Total % Received % Xferd Average Speed Time Time Time Current
                                 Dload Upload Total Spent Left Speed
  0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
HTTP/2 301
server: nginx
date: Fri, 31 Oct 2025 06:59:31 GMT
content-type: text/html; charset=iso-8859-1
x-content-type-options: nosniff
x-frame-options: SAMEORIGIN
x-permitted-cross-domain-policies: none
x-robots-tag: noindex, nofollow
referrer-policy: no-referrer
location: http://cloud.mydomain.tld/remote.php/dav/
strict-transport-security: max-age=15768000; includeSubdomains; preload

```

I couldn’t find any direct error message, but when the container starts, I get this message, can this be related?

`AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 172.20.0.4. Set the 'ServerName' directive globally to suppress this message`

---

<div class="post-metadata">

**Author:** ![wwe](https://help.nextcloud.com/user_avatar/help.nextcloud.com/wwe/32/72963_2.png) [@wwe](https://help.nextcloud.com/u/wwe)\
**Post date:** [October 31, 2025, 10:10am UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/6 "2025-10-31T10:10:29Z")

</div>

> [@Thor](#):
>
> ```auto
> docker exec nextcloud_app curl -I https://cloud.mydomain.tld/.well-known/caldav
> ...
> location: http://cloud.mydomain.tld/remote.php/dav/
> 
> ```

is there a reason why you redirect to http:// ?

---

<div class="post-metadata">

**Author:** ![Thor](https://help.nextcloud.com/user_avatar/help.nextcloud.com/thor/32/521_2.png) [@Thor](https://help.nextcloud.com/u/Thor)\
**Post date:** [October 31, 2025, 11:40am UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/7 "2025-10-31T11:40:24Z")

</div>

The container internally only has http as far as I understood.  
The container runs behind a reverse proxy that only allows https.  
Also in the config I have set ‘overwriteprotocol’ =\> ‘https’,

I don’t redirect anything on my own, the .htaccess is part of the container.

---

<div class="post-metadata">

**Author:** ![wwe](https://help.nextcloud.com/user_avatar/help.nextcloud.com/wwe/32/72963_2.png) [@wwe](https://help.nextcloud.com/u/wwe)\
**Post date:** [October 31, 2025, 8:45pm UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/8 "2025-10-31T20:45:32Z")

</div>

> [@Thor](#):
>
> `server: nginx`

looks like your #reverseproxy is doing the redirect..

---

<div class="post-metadata">

**Author:** ![Thor](https://help.nextcloud.com/user_avatar/help.nextcloud.com/thor/32/521_2.png) [@Thor](https://help.nextcloud.com/u/Thor)\
**Post date:** [October 31, 2025, 10:28pm UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/9 "2025-10-31T22:28:01Z")

</div>

again, I don’t know how this post is supposed to help.  
I set up the container based on the documentation, taking into account the config settings for the reverse proxy.

Those are the settings of the reverse proxy. Same settings are mentioned in tutorials and the nextcloud-aio github page.

 ![proxy1](https://help.nextcloud.com/uploads/default/original/3X/1/9/19028b321f3d76ac646cd324eb91a6261e8fd005.png)#

 ![proxy2](https://help.nextcloud.com/uploads/default/original/3X/c/1/c145738ebe215254fcde00afc1d12e31a2da4093.png)

The redirect works for anyone outside, based on your explanation, the redirect is not working on the server side.  
Still I don’t understand why the error message only shows up for caldav not for carddav.

So, no the reverse proxy is not redirecting /well-known. I can show you the complete reverse-proxy conf file, if that helps.

---

<div class="post-metadata">

**Author:** ![jtr](https://help.nextcloud.com/letter_avatar/jtr/32/6_22734026db12803ebb3e059622ac3534.png) [@jtr](https://help.nextcloud.com/u/jtr)\
**Post date:** [November 1, 2025, 2:44am UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/10 "2025-11-01T02:44:03Z")

</div>

Please post your actual Nextcloud config (as noted in the [support template](https://help.nextcloud.com/t/support-template-please-use-this-when-you-request-support/137402) and do so by using `occ config:list system` preferably since most of the Docker images used multiple config files + environment variable injection so just looking at config.php isn’t enough) as well as your Docker Compose.

Based on a few clues in the thread so far, don’t believe you’re actually using the AIO image/stack. Possiblly the community micro-services image, but there are other possibilities.

Also, can you clarify specifically what RP you’re using? Standard `nginx` does not have that UI. It appears to be one of the third party ones, possibly Synology’s.

---

<div class="post-metadata">

**Author:** ![Thor](https://help.nextcloud.com/user_avatar/help.nextcloud.com/thor/32/521_2.png) [@Thor](https://help.nextcloud.com/u/Thor)\
**Post date:** [November 1, 2025, 7:43am UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/11 "2025-11-01T07:43:27Z")

</div>

Yes, it is not the AIO image, it is the community one. I just went through several resources to verify if a special setup for the RP is needed and yes it is the Synology RP.

Docker Compose:

```auto
services:
  mariadb:
    image: mariadb:11.5.2
    container_name: nextcloud_mariadb
    restart: unless-stopped
    networks:
      - nextcloud
    volumes:
      - ./mariadb:/var/lib/mysql
    environment:
      - MARIADB_ALLOW_EMPTY_ROOT_PASSWORD=1

  redis:
    image: redis:alpine
    container_name: nextcloud_redis
    restart: unless-stopped
    command: redis-server --requirepass Th1s-1s-a-pa22phra2e-for-red12
    networks:
      - nextcloud
  
  nextcloud:
    image: nextcloud:32.0.1
    container_name: nextcloud_app
    depends_on:
      mariadb:
        condition: service_started
      redis:
        condition: service_started
    restart: unless-stopped
    ports:
      - 81:80
    links:
      - mariadb
      - redis
    networks:
      - nextcloud
    volumes: 
      - ./apps:/var/www/html/custom_apps
      - ./config:/var/www/html/config
      - ./data:/var/www/html/data 
      - ./nextcloud:/var/www/html
      - ./themes:/var/www/html/themes/custom
      - /volume1/photo/Test:/test
    environment:
      - PHP_MEMORY_LIMIT=4048M
      - PHP_UPLOAD_LIMIT=4048M
      - TRUSTED_PROXIES=192.168.13.201
      - OVERWRITEHOST=todo.viking-studios.net
      - OVERWRITEPROTOCOL=https
      - OVERWRITECLIURL=https://todo.viking-studios.net
      - REDIS_HOST=redis
      - REDIS_PORT=6379
      - REDIS_HOST_PASSWORD=Th1s-1s-a-pa22phra2e-for-red12

networks:
  nextcloud:
    name: nextcloud
    driver: bridge

```

And the config

```auto
{
“system”:
{
“htaccess.RewriteBase”: “/”,
“apps_paths”: [
  {“path”: “/var/www/html/apps”,
  “url”: “/apps”,“writable”: false},
  {“path”: “/var/www/html/custom_apps”,
  “url”: “/custom_apps”,“writable”: true}],
“overwritehost”: “REMOVED SENSITIVE VALUE”,
“overwriteprotocol”: “https”,
“overwrite.cli.url”: “REMOVED SENSITIVE VALUE”,
“trusted_proxies”: “REMOVED SENSITIVE VALUE”,
“upgrade.disable-web”: true,
“instanceid”: “REMOVED SENSITIVE VALUE”,
“passwordsalt”: “REMOVED SENSITIVE VALUE”,
“secret”: “REMOVED SENSITIVE VALUE”,
“trusted_domains”: [“REMOVED SENSITIVE VALUE”],
“datadirectory”: “REMOVED SENSITIVE VALUE”,
“dbtype”: “mysql”,
“version”: “32.0.1.2”,
“dbname”: “REMOVED SENSITIVE VALUE”,
“dbhost”: “REMOVED SENSITIVE VALUE”,
“dbtableprefix”: “oc_”,
“memcache.local”: “\OC\Memcache\APCu”,
“memcache.distributed”: “\OC\Memcache\Redis”,
“memcache.locking”: “\OC\Memcache\Redis”,
“redis”: 
  {“host”: “REMOVED SENSITIVE VALUE”,
  “password”: “REMOVED SENSITIVE VALUE”,
  “port”: 6379},
“mysql.utf8mb4”: true,
“dbuser”: “REMOVED SENSITIVE VALUE”,
“dbpassword”: “REMOVED SENSITIVE VALUE”,
“installed”: true,
“maintenance”: false}}

```

---

<div class="post-metadata">

**Author:** ![Thor](https://help.nextcloud.com/user_avatar/help.nextcloud.com/thor/32/521_2.png) [@Thor](https://help.nextcloud.com/u/Thor)\
**Post date:** [November 2, 2025, 12:21am UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/12 "2025-11-02T00:21:34Z")

</div>

I could fix it.  
The solution is from [here](https://help.nextcloud.com/t/webserver-well-known-caldav-synology-docker-nextcloud-nginx-caldav-carddav/83876/24)

Based on the fact that the issue is a check, that is running on the server, the issue shouldn’t be related to the reverse proxy (correct me, if my assumption is wrong).  
The NC server is running on apache that is part of the container.  
As initially stated, there are a ton of threads, posts and tutorials on many sides that are somehow related to well-known issues stating more or less the same solution and the .htaccess within the container matched those solutions.  
I fund that thread more or less by accident, looking for something different.

---

<div class="post-metadata">

**Author:** ![system](https://help.nextcloud.com/user_avatar/help.nextcloud.com/system/32/29333_2.png) [@system](https://help.nextcloud.com/u/system)\
**Post date:** [November 10, 2025, 12:22am UTC](https://help.nextcloud.com/t/well-known-caldav-error-in-docker-container/234717/13 "2025-11-10T00:22:15Z")

</div>

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