How to enable SVG for php-imagick

For me the same. I use a docker installation and cannot install it all the time. That should be integrated into the image of nextcloud

1 Like

The same go’s for me. They should include the package in the docker image.


Hello, I had the same problem. And I solved it with these steps:

if you are using docker then:
1 . find out the docker container ID–> docker ps
2 isuue command → docker exec CONTAINER ID /bin/bash -c ‘apt update && apt install -y libmagickcore-6.q16-6-extra’

I works for me. But after giving docker-compose down and docker-compose up -d, The problem is there again. I read this is Version 21 problem. and have not found a perment solution yet. However, SVG warning is not critical.

I hope this helps


My problem here: libmagickcore-6.q16-6-extra is already the newest version (8:,
php-imagick is already the newest version (
and imagemagick is already the newest version (8:
All installed on one machine, no Docker

1 Like

You can create a new docker image based on the official Nextcloud image to add extra features.

FROM nextcloud:21-fpm

RUN apt-get update && apt-get install -y smbclient libsmbclient-dev libmagickwand-dev && rm -rf /var/lib/apt/lists/*

RUN pecl install inotify && docker-php-ext-enable inotify
RUN pecl install smbclient && docker-php-ext-enable smbclient
1 Like

When doing the same as ‘DecaTec’ has done, i recognize some php8.0 installations. I’m feared now. I remember having seen similar on my nextcloud predecessor instance when doing some regular updates and the the server became unusable. I don’t know if it does not boot at all but in any case i can’t ssh anymore as well as connect NC-Instance. It was Raspberry Pi 3B with 32bit OS, NC20. Recent instance (new from scratch) is NC21 on RPI 4B 64bit OS.

I’m feared to reboot now :open_mouth:

Does your server behave as expected?

Suggestions welcome, thx

I received prompts that the latests versions were already installed on my Ubuntu 20.04 server.

I had to manually uninstall the imagemagick and php-imagick packages:
sudo apt remove imagemagick
sudo apt remove php-imagick

Then install them again using:
sudo apt install php-imagick imagemagick

All checks passed after that.


Thanks!!! Remove with purge then install works for me (NC21, Ubuntu 20.04.2, PHP 7.4.9).

True but in the mean time you can docker exec into the nextcloud app container (if you annoyed with the warning like me), like in my case:

docker exec -it --user root nextcloud_app_1 apt update
docker exec -it --user root nextcloud_app_1 apt install imagemagick


@jurgenhaas I’m having the same issue, could you detail your solution? What options did you use to enable SVG. Did you compile and manually install imagemagick or php-imagick? or both?

@christiancloud I’m not having a solution, unfortunately. When I posted this issue here, I tried everything possible. Installing, updating, reinstalling all sorts of components. With no luck.

But what’s even more strange: eventually the warning from NC 21 disappared. I really have no idea what “solved” the problem - I just know it wasn’t be, at least not intentional.

Reinstalling worked for me as well. Anyhow I had to reboot the server afterwards.

1 Like

Hi, I have the same issue with NC21 docker image. I can install libmagickcore-6.q16-6-extra and it works but I must do the same each time I restart the container.
Is it possible to fix it ?
Thank you.

I have a custom Nextcloud Docker image I use that extends the base image and adds GhostScript for PDF previews, clamdscan for AV (I run a separate ClamAV image), libmagickcore-6.q16-6-extra for SVG support, and a few other tweaks. Source code available on my GitLab and builds are in Docker Hub at koehn/nextcloud.


This helped for me too. Thanks

1 Like

This worked for me with this particular issue. Thanks.

1 Like

It worked for me though.

1 Like

On my side this installation fixed the problem

IMHO the point here is: why there is a warning about the php-imagick missing if it is an “unsupported feature” due to security concerns ?
I can see the effect of the decision in the missing package(s) in the docker image but the warning is confusing (and annoying :smiley: )…
I think the issue is tracked here and here


Worked for me too, thanks!

1 Like