# Does imagemagick need an update to support HEIC photos from latest iOS?

**URL:** <https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631>\
**Category:** ℹ️ Support\
**Tags:** docker, nc28, teamfolders-app, ncp, ios, aio, postgresql\
**Created:** [December 5, 2024, 4:41pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631 "2024-12-05T16:41:49Z")\
**Posts on this page:** 18\
**Page:** 1

<div class="post-metadata">

**Author:** ![TobiasEigen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/tobiaseigen/32/79976_2.png) [@TobiasEigen](https://help.nextcloud.com/u/TobiasEigen)\
**Post date:** [December 5, 2024, 4:41pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/1 "2024-12-05T16:41:49Z")

</div>

> ⚠ I crossposted this as a bug report on github:
> 
> [https://github.com/nextcloud/all-in-one/issues/5709#issue-2721354279](https://github.com/nextcloud/all-in-one/issues/5709#issue-2721354279)

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can. ❤

## The Basics

- Nextcloud Server version _(e.g., 29.x.x)_:
  - `Nextcloud Hub 9 (30.0.2)`

- Operating system and version _(e.g., Ubuntu 24.04)_:
  - `Ubuntu 22.04.5 LTS (GNU/Linux 5.15.0-126-generic x86_64)`

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

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

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

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

- When did this problem seem to first start?
  - `November 26`

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

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

### Summary of the issue you are facing:

Last week, previews stopped showing up for new photos taken on my iphone and uploaded to nextcloud. I am getting thousands of errors showing up in the log. This appears to be related to a problem with imagemagick which has been fixed in recent upgrades. Do we need to upgrade the imagemagick that ships with AIO?

[https://github.com/ImageMagick/ImageMagick/discussions/7426](https://github.com/ImageMagick/ImageMagick/discussions/7426)

ImageMagick version that ships with AIO currently is 7.1.1-32. Most recent version is 7.1.1-41.

```auto
root@2024-nextcloud-ubuntu-s-2vcpu-4gb-120gb-intel-nyc3-01:~# sudo docker exec --user www-data -it nextcloud-aio-nextcloud magick --version
Version: ImageMagick 7.1.1-32 Q16-HDRI x86_64 22207 https://imagemagick.org
Copyright: (C) 1999 ImageMagick Studio LLC
License: https://imagemagick.org/script/license.php
Features: Cipher DPC HDRI Modules OpenMP(4.5) 
Delegates (built-in): bzlib cairo fftw fontconfig freetype gslib heic jng jpeg jxl lcms ltdl lzma pangocairo png ps raw rsvg tiff webp x xml zlib zstd
Compiler: gcc (13.2)

```

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

1. Take some photos using iphone with iOS 18.1.1
2. upload photos to nextcloud
3. see that previews are not generated  
 ![Screenshot 2024-12-05 at 8.29.29 AM](https://help.nextcloud.com/uploads/default/original/3X/4/4/44a5790fdfb69be84ce2926d84822af2317bdde4.png)
4. visit logs to see errors

Also, running magick from console generates the same error when processing a photo taken since I upgraded my iphone:

```auto
root@2024-nextcloud-ubuntu-s-2vcpu-4gb-120gb-intel-nyc3-01:~# sudo docker exec --user www-data -it nextcloud-aio-nextcloud magick identify -format "%m,%w,%h\n%[EXIF:*]" "/mnt/ncdata/nnn-1/files/nnn Photos/2024/12/24-12-03 08-50-07 7496.heic"
identify: Invalid input: Unspecified: Metadata not correctly assigned to image (2.0) `/mnt/ncdata/nnn-1/files/nnn Photos/2024/12/24-12-03 08-50-07 7496.heic' @ error/heic.c/IsHEIFSuccess/144.

```

As compared to processing an older photo that works:

```auto
root@2024-nextcloud-ubuntu-s-2vcpu-4gb-120gb-intel-nyc3-01:/mnt/volume_nyc3_01/nextcloud/backup/files/backup/Photos Library/2024/2024-01-22# sudo docker exec --user www-data -it nextcloud-aio-nextcloud magick identify -format "%m,%w,%h\n%[EXIF:*]" "/mnt/ncdata/backup/files/backup/Photos Library/2024/2024-01-22/IMG_4752.HEIC"
HEIC,4284,5712
exif:ApertureValue=171202/102901
exif:BrightnessValue=12291/69091
exif:ColorSpace=65535
exif:DateTime=2024:01:22 17:23:32
exif:DateTimeDigitized=2024:01:22 17:23:32
exif:DateTimeOriginal=2024:01:22 17:23:32
exif:ExifOffset=220
exif:ExifVersion=0232
exif:ExposureBiasValue=0/1
exif:ExposureMode=0
exif:ExposureProgram=2
exif:ExposureTime=1/60
exif:Flash=16
exif:FNumber=89/50
exif:FocalLength=343/50
exif:FocalLengthIn35mmFilm=24
exif:LensMake=Apple
exif:LensModel=iPhone 15 Pro Max back triple camera 6.86mm f/1.78
exif:LensSpecification=1551800/699009, 1551800/699009, 1551800/699009, 1551800/699009
exif:Make=Apple
exif:MakerNote=Apple iOS
exif:MeteringMode=5
exif:Model=iPhone 15 Pro Max
exif:OffsetTime=-08:00
exif:OffsetTimeDigitized=-08:00
exif:OffsetTimeOriginal=-08:00
exif:Orientation=6
exif:PhotographicSensitivity=800
exif:PixelXDimension=5712
exif:PixelYDimension=4284
exif:ResolutionUnit=2
exif:SceneType=.
exif:SensingMethod=2
exif:ShutterSpeedValue=73847/12503
exif:Software=17.2.1
exif:SubjectArea=1087, 1087, 1087, 1087
exif:SubSecTimeDigitized=976
exif:SubSecTimeOriginal=976
exif:WhiteBalance=0
exif:XResolution=72/1
exif:YResolution=72/1

```

### Log entries

#### Nextcloud

Please provide the log entries from your Nextcloud log that are generated during the time of problem (via the _Copy raw_ option from _Administration settings-\>Logging_ screen or from your `nextcloud.log` located in your data directory). Feel free to use a pastebin/gist service if necessary.

```auto
{"reqId":"9nw4pSuDjfpHdNkf4gSO","level":3,"time":"2024-12-05T16:29:21+00:00","remoteAddr":"73.19.12.15","user":"nnn-1","app":"core","method":"GET","url":"/core/preview?fileId=1643779&x=250&y=250","message":"File: /nnn-1/files/nnn Photos/2024/12/24-12-03 08-50-07 7496.heic Imagick says:","userAgent":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36","version":"30.0.2.2","exception":{"Exception":"ImagickException","Message":"Invalid input: Unspecified: Metadata not correctly assigned to image (2.0) `/mnt/ncdata/nnn-1/files/nnn Photos/2024/12/24-12-03 08-50-07 7496.heic' @ error/heic.c/IsHEIFSuccess/144","Code":425,"Trace":[{"file":"/var/www/html/lib/private/Preview/HEIC.php","line":99,"function":"pingImage","class":"Imagick","type":"->","args":["/mnt/ncdata/nnn-1/files/nnn Photos/2024/12/24-12-03 08-50-07 7496.heic[0]"]},{"file":"/var/www/html/lib/private/Preview/HEIC.php","line":56,"function":"getResizedPreview","class":"OC\\Preview\\HEIC","type":"->","args":["/mnt/ncdata/nnn-1/files/nnn Photos/2024/12/24-12-03 08-50-07 7496.heic",2048,2048]},{"file":"/var/www/html/lib/private/Preview/GeneratorHelper.php","line":44,"function":"getThumbnail","class":"OC\\Preview\\HEIC","type":"->","args":[{" __class__":"OC\\Files\\Node\\File"},2048,2048]},{"file":"/var/www/html/lib/private/Preview/Generator.php","line":337,"function":"getThumbnail","class":"OC\\Preview\\GeneratorHelper","type":"->","args":[{" __class__":"OC\\Preview\\HEIC"},{" __class__":"OC\\Files\\Node\\File"},2048,2048]},{"file":"/var/www/html/lib/private/Preview/Generator.php","line":313,"function":"generateProviderPreview","class":"OC\\Preview\\Generator","type":"->","args":[{" __class__":"OC\\Files\\SimpleFS\\SimpleFolder"},{" __class__":"OC\\Files\\Node\\File"},2048,2048,false,true,"image/heic",""]},{"file":"/var/www/html/lib/private/Preview/Generator.php","line":119,"function":"getMaxPreview","class":"OC\\Preview\\Generator","type":"->","args":[{" __class__":"OC\\Files\\SimpleFS\\SimpleFolder"},[],{" __class__":"OC\\Files\\Node\\File"},"image/heic",""]},{"file":"/var/www/html/lib/private/Preview/Generator.php","line":86,"function":"generatePreviews","class":"OC\\Preview\\Generator","type":"->","args":[{" __class__":"OC\\Files\\Node\\File"},[{"width":250,"height":250,"crop":true,"mode":"fill"}],"image/heic"]},{"file":"/var/www/html/lib/private/PreviewManager.php","line":167,"function":"getPreview","class":"OC\\Preview\\Generator","type":"->","args":[{" __class__":"OC\\Files\\Node\\File"},250,250,true,"fill",null]},{"file":"/var/www/html/core/Controller/PreviewController.php","line":159,"function":"getPreview","class":"OC\\PreviewManager","type":"->","args":[{" __class__":"OC\\Files\\Node\\File"},250,250,true,"fill"]},{"file":"/var/www/html/core/Controller/PreviewController.php","line":123,"function":"fetchPreview","class":"OC\\Core\\Controller\\PreviewController","type":"->","args":[{" __class__":"OC\\Files\\Node\\File"},250,250,false,true,"fill",false]},{"file":"/var/www/html/lib/private/AppFramework/Http/Dispatcher.php","line":208,"function":"getPreviewByFileId","class":"OC\\Core\\Controller\\PreviewController","type":"->","args":[1643779,250,250,false,true,"fill",false]},{"file":"/var/www/html/lib/private/AppFramework/Http/Dispatcher.php","line":114,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[{" __class__":"OC\\Core\\Controller\\PreviewController"},"getPreviewByFileId"]},{"file":"/var/www/html/lib/private/AppFramework/App.php","line":161,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[{" __class__":"OC\\Core\\Controller\\PreviewController"},"getPreviewByFileId"]},{"file":"/var/www/html/lib/private/Route/Router.php","line":302,"function":"main","class":"OC\\AppFramework\\App","type":"::","args":["OC\\Core\\Controller\\PreviewController","getPreviewByFileId",{" __class__":"OC\\AppFramework\\DependencyInjection\\DIContainer"},{"_route":"core.preview.getpreviewbyfileid"}]},{"file":"/var/www/html/lib/base.php","line":1001,"function":"match","class":"OC\\Route\\Router","type":"->","args":["/core/preview"]},{"file":"/var/www/html/index.php","line":24,"function":"handleRequest","class":"OC","type":"::","args":[]}],"File":"/var/www/html/lib/private/Preview/HEIC.php","Line":99,"message":"File: /nnn-1/files/nnn Photos/2024/12/24-12-03 08-50-07 7496.heic Imagick says:","exception":[],"CustomMessage":"File: /nnn-1/files/nnn Photos/2024/12/24-12-03 08-50-07 7496.heic Imagick says:"},"id":"6751d55c59697"}

```

#### Web Browser

If the problem is related to the Web interface, open your browser inspector _Console_ and _Network_ tabs while refreshing (reloading) and reproducing the problem. Provide any relevant output/errors here that appear.

```auto
PASTE

```

#### Web server / Reverse Proxy

The output of your Apache/nginx/system log in `/var/log/ ____ `:

```auto
PASTE HERE

```

### Configuration

#### Nextcloud

The output of `occ config:list system` or similar is best, but, if not possible, the contents of your `config.php` file from `/path/to/nextcloud` is fine (make sure to remove any identifiable information!):

```auto
{
    "system": {
        "one-click-instance": true,
        "one-click-instance.user-limit": 100,
        "memcache.local": "\\OC\\Memcache\\APCu",
        "apps_paths": [
            {
                "path": "\/var\/www\/html\/apps",
                "url": "\/apps",
                "writable": false
            },
            {
                "path": "\/var\/www\/html\/custom_apps",
                "url": "\/custom_apps",
                "writable": true
            }
        ],
        "appsallowlist": false,
        "check_data_directory_permissions": false,
        "memcache.distributed": "\\OC\\Memcache\\Redis",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": " ***REMOVED SENSITIVE VALUE***",
            "password": " ***REMOVED SENSITIVE VALUE***",
            "port": 6379
        },
        "overwritehost": "nextcloud.nnn.org",
        "overwriteprotocol": "https",
        "passwordsalt": " ***REMOVED SENSITIVE VALUE***",
        "secret": " ***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "localhost",
            "nextcloud.nnn.org"
        ],
        "datadirectory": " ***REMOVED SENSITIVE VALUE***",
        "dbtype": "pgsql",
        "version": "30.0.2.2",
        "overwrite.cli.url": "https:\/\/nextcloud.nnn.org\/",
        "dbname": " ***REMOVED SENSITIVE VALUE***",
        "dbhost": " ***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "dbuser": " ***REMOVED SENSITIVE VALUE***",
        "dbpassword": " ***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "instanceid": " ***REMOVED SENSITIVE VALUE***",
        "maintenance": false,
        "loglevel": 2,
        "log_type": "file",
        "logfile": "\/var\/www\/html\/data\/nextcloud.log",
        "log_rotate_size": "10485760",
        "log.condition": {
            "apps": [
                "admin_audit"
            ]
        },
        "preview_max_x": 2048,
        "preview_max_y": 2048,
        "jpeg_quality": 60,
        "enabledPreviewProviders": [
            "OC\\Preview\\MP3",
            "OC\\Preview\\TXT",
            "OC\\Preview\\OpenDocument",
            "OC\\Preview\\Movie",
            "OC\\Preview\\Krita",
            "OC\\Preview\\HEIC",
            "OC\\Preview\\TIFF",
            "OC\\Preview\\Image"
        ],
        "enable_previews": true,
        "upgrade.disable-web": true,
        "mail_smtpmode": "smtp",
        "trashbin_retention_obligation": "auto, 30",
        "versions_retention_obligation": "auto, 30",
        "activity_expire_days": "30",
        "simpleSignUpLink.shown": false,
        "share_folder": "\/Shared",
        "one-click-instance.link": "https:\/\/nextcloud.com\/all-in-one\/",
        "upgrade.cli-upgrade-link": "https:\/\/github.com\/nextcloud\/all-in-one\/discussions\/2726",
        "updatedirectory": "\/nc-updater",
        "maintenance_window_start": 100,
        "allow_local_remote_servers": true,
        "davstorage.request_timeout": 3600,
        "htaccess.RewriteBase": "\/",
        "dbpersistent": false,
        "auth.bruteforce.protection.enabled": true,
        "ratelimit.protection.enabled": true,
        "files_external_allow_create_new_local": false,
        "trusted_proxies": " ***REMOVED SENSITIVE VALUE***",
        "preview_imaginary_key": " ***REMOVED SENSITIVE VALUE***",
        "mail_from_address": " ***REMOVED SENSITIVE VALUE***",
        "mail_sendmailmode": "smtp",
        "mail_domain": " ***REMOVED SENSITIVE VALUE***",
        "mail_smtphost": " ***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "25",
        "mail_smtpauth": 1,
        "mail_smtpname": " ***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": " ***REMOVED SENSITIVE VALUE***",
        "memories.db.triggers.fcu": true,
        "memories.exiftool": "\/var\/www\/html\/custom_apps\/memories\/bin-ext\/exiftool-amd64-musl",
        "memories.vod.path": "\/var\/www\/html\/custom_apps\/memories\/bin-ext\/go-vod-amd64",
        "memories.vod.ffmpeg": "\/usr\/bin\/ffmpeg",
        "memories.vod.ffprobe": "\/usr\/bin\/ffprobe",
        "memories.gis_type": 2,
        "default_phone_region": "US",
        "defaultapp": "files,keeweb,memories",
        "memories.vod.disable": false,
        "documentation_url.server_logs": "https:\/\/github.com\/nextcloud\/all-in-one\/discussions\/5425",
        "preview_imaginary_url": " ***REMOVED SENSITIVE VALUE***",
        "DOMAIN": "nextcloud.nnn.org"
    }
}

```

#### Apps

The output of `occ app:list` (if possible).

```auto
Enabled:
  - activity: 3.0.0
  - app_api: 4.0.0
  - bruteforcesettings: 3.0.0
  - cloud_federation_api: 1.13.0
  - dav: 1.31.1
  - external: 5.5.2
  - federatedfilesharing: 1.20.0
  - files: 2.2.0
  - files_downloadlimit: 3.0.0
  - files_pdfviewer: 3.0.0
  - files_sharing: 1.22.0
  - files_trashbin: 1.20.1
  - files_versions: 1.23.0
  - keeweb: 0.6.20
  - logreader: 3.0.0
  - lookup_server_connector: 1.18.0
  - memories: 7.4.1
  - nextcloud-aio: 0.7.0
  - notes: 4.11.0
  - notify_push: 0.7.0
  - oauth2: 1.18.1
  - password_policy: 2.0.0
  - photos: 3.0.2
  - previewgenerator: 5.7.0
  - provisioning_api: 1.20.0
  - recognize: 8.1.1
  - recommendations: 3.0.0
  - related_resources: 1.5.0
  - serverinfo: 2.0.0
  - settings: 1.13.0
  - sociallogin: 5.7.0
  - support: 2.0.0
  - systemtags: 1.20.0
  - theming: 2.5.0
  - twofactor_backupcodes: 1.19.0
  - unroundedcorners: 1.1.4
  - viewer: 3.0.0
  - webhook_listeners: 1.1.0-dev
  - workflowengine: 2.12.0
Disabled:
  - admin_audit: 1.20.0 (installed 1.18.0)
  - calendar: 5.0.6 (installed 5.0.6)
  - circles: 30.0.0 (installed 28.0.0)
  - comments: 1.20.1 (installed 1.18.0)
  - contacts: 6.1.1 (installed 6.1.1)
  - contactsinteraction: 1.11.0 (installed 1.9.0)
  - dashboard: 7.10.0 (installed 7.8.0)
  - deck: 1.14.2 (installed 1.14.2)
  - encryption: 2.18.0
  - federation: 1.20.0 (installed 1.18.0)
  - files_archive: 1.2.3 (installed 1.2.3)
  - files_external: 1.22.0
  - files_reminders: 1.3.0 (installed 1.1.0)
  - firstrunwizard: 3.0.0 (installed 2.17.0)
  - groupfolders: 18.0.6 (installed 18.0.6)
  - maps: 1.5.0 (installed 1.5.0)
  - nextcloud_announcements: 2.0.0 (installed 1.17.0)
  - notifications: 3.0.0 (installed 2.16.0)
  - privacy: 2.0.0 (installed 1.12.0)
  - sharebymail: 1.20.0 (installed 1.18.0)
  - side_menu: 4.0.1 (installed 4.0.1)
  - survey_client: 2.0.0 (installed 1.16.0)
  - suspicious_login: 8.0.0
  - tasks: 0.16.1 (installed 0.16.1)
  - text: 4.1.0 (installed 3.9.1)
  - theming_customcss: 1.17.0 (installed 1.17.0)
  - twofactor_nextcloud_notification: 4.0.0
  - twofactor_totp: 12.0.0-dev (installed 10.0.0-beta.2)
  - user_ldap: 1.21.0
  - user_status: 1.10.0 (installed 1.8.1)
  - weather_status: 1.10.0 (installed 1.8.0)

```

### Tips for increasing the likelihood of a response

- Use the `preformatted text` formatting option in the editor for all log entries and configuration output.
- If screenshots are useful, feel free to include them.
  - If possible, also include key error output in text form so it can be searched for.

- Try to edit log output only minimally (if at all) so that it can be ran through analyzers / formatters by those trying to help you.

---

<div class="post-metadata">

**Author:** ![rakekniven](https://help.nextcloud.com/user_avatar/help.nextcloud.com/rakekniven/32/67096_2.png) [@rakekniven](https://help.nextcloud.com/u/rakekniven)\
**Post date:** [December 5, 2024, 5:01pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/2 "2024-12-05T17:01:22Z")

</div>

Hello Tobias,

if you get no response here I would file an issue at [GitHub · Where software is built](https://github.com/nextcloud/all-in-one/issues) .  
Please leave a ref here if you do so.

---

<div class="post-metadata">

**Author:** ![Andi29](https://help.nextcloud.com/user_avatar/help.nextcloud.com/andi29/32/66628_2.png) [@Andi29](https://help.nextcloud.com/u/Andi29)\
**Post date:** [December 5, 2024, 6:05pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/3 "2024-12-05T18:05:55Z")

</div>

Hi, mean there was an app in nextcloud store for .heic-format. Maybe it helps.  
[heic to jpg](https://apps.nextcloud.com/apps/imageconverter)

---

<div class="post-metadata">

**Author:** ![TobiasEigen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/tobiaseigen/32/79976_2.png) [@TobiasEigen](https://help.nextcloud.com/u/TobiasEigen)\
**Post date:** [December 5, 2024, 6:27pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/4 "2024-12-05T18:27:45Z")

</div>

Thanks for that suggestion! I am aware of that app but am not interested in converting or changing the file format. I think the answer here is to upgrade imagemagick in AIO to the latest version that fixes this issue.

---

<div class="post-metadata">

**Author:** ![Andi29](https://help.nextcloud.com/user_avatar/help.nextcloud.com/andi29/32/66628_2.png) [@Andi29](https://help.nextcloud.com/u/Andi29)\
**Post date:** [December 5, 2024, 6:42pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/5 "2024-12-05T18:42:02Z")

</div>

Sorry. But I´m very sure in the app-strore, was an addone for heic-format.

---

<div class="post-metadata">

**Author:** ![TobiasEigen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/tobiaseigen/32/79976_2.png) [@TobiasEigen](https://help.nextcloud.com/u/TobiasEigen)\
**Post date:** [December 5, 2024, 7:08pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/6 "2024-12-05T19:08:17Z")

</div>

Thanks, but there is already HEIC support out of the box in Nextcloud AIO.

---

<div class="post-metadata">

**Author:** ![bb77](https://help.nextcloud.com/letter_avatar/bb77/32/5_5575768a8748004e209b776fc1b2916d.png) [@bb77](https://help.nextcloud.com/u/bb77)\
**Post date:** [December 5, 2024, 7:29pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/7 "2024-12-05T19:29:10Z")

</div>

> [@TobiasEigen](#):
>
> HEIC

HEIC is not a image format, but a container. The actual image format is called HEIF.  
/smartarsemodeoff 😉

And unfortunately, as it is the case with many media formats, although HEIF is an ISO standard, there are many ‘brand’ specific (they littreally call them brands) implementations, which makes it difficult for OSS projects to implement them: [High Efficiency Image File Format - Wikipedia](https://en.wikipedia.org/wiki/High_Efficiency_Image_File_Format)

I found the following issue and discussion on GitHub, maybe they are of any help:

> <https://github.com/Imagick/imagick/issues/675>
>
> I updated to iOS 18, and my HEIC images are no longer processed by imagick in Ne…xtcloud. Where iOS is still in beta it may not be an issue, but it's probably something to keep an eye on as development continues. 
> 
> The error it gives in Nextcloud is "ImagickException Failed to read the file".

> **[Failure to process HEIC images taken on iOS18 iPhone · ImageMagick ImageMagick...](https://github.com/ImageMagick/ImageMagick/discussions/7426)**
>
> ImageMagick version 7.1.0-61 Operating system, version and so on Common Base Linux Mariner 2.0.20240223 #59-Ubuntu Description Hi imagemagick experts, I found an issue related to HEIC images taken ...

---

<div class="post-metadata">

**Author:** ![TobiasEigen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/tobiaseigen/32/79976_2.png) [@TobiasEigen](https://help.nextcloud.com/u/TobiasEigen)\
**Post date:** [December 5, 2024, 8:08pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/8 "2024-12-05T20:08:16Z")

</div>

It’s cool. Nice to be able to troubleshoot this with a smart person. 🕶 🧠 💡

I saw those github links too and the second one I had already included in the OP. My feeling from that research is that updating imagemagick in AIO will do the trick.

Do you know how I might do the update temporarily just to test, knowing that next time I rebuild the container my changes will be lost?

---

<div class="post-metadata">

**Author:** ![bb77](https://help.nextcloud.com/letter_avatar/bb77/32/5_5575768a8748004e209b776fc1b2916d.png) [@bb77](https://help.nextcloud.com/u/bb77)\
**Post date:** [December 5, 2024, 8:37pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/9 "2024-12-05T20:37:01Z")

</div>

> [@TobiasEigen](#):
>
> Do you know how I might do the update temporarily just to tes

Unfortunately I don’t, but as far as I know the AIO containers are based on Alpine, so if the latest version of imagemagick does indeed fix the problem, it depends on whether Alpine has the latest imagemagick version in their repos, and if not, whether it is possible to compile the latest version inside the respective AIO container. I mean, in theory it’s certainly possible, in practice I’d probably wait until @szaimen is updating the container image. 😉

EDIT:  
You could of course also install Nextcloud manually on a system with the latest imagemagick package installed to test it, but I’m not sure if that’s worth the hassle.

---

<div class="post-metadata">

**Author:** ![TobiasEigen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/tobiaseigen/32/79976_2.png) [@TobiasEigen](https://help.nextcloud.com/u/TobiasEigen)\
**Post date:** [December 5, 2024, 8:50pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/10 "2024-12-05T20:50:05Z")

</div>

Yeah, I guess I will have to be patient and see what happens. Feeling a bit out of sorts though given that this is broken and I rely on it so much in my family for managing and sharing photos. 😭

If nothing happens I will see about just updating imagemagick in the container. It should work but is risky because any change will be overwritten with the next rebuild of AIO.

I crossposted this as a bug report on github: [HEIC photos taken on iOS 18.1.1 are not being processed correctly by imagemagick · Issue #5709 · nextcloud/all-in-one · GitHub](https://github.com/nextcloud/all-in-one/issues/5709#issue-2721354279)

---

<div class="post-metadata">

**Author:** ![bb77](https://help.nextcloud.com/letter_avatar/bb77/32/5_5575768a8748004e209b776fc1b2916d.png) [@bb77](https://help.nextcloud.com/u/bb77)\
**Post date:** [December 5, 2024, 9:17pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/11 "2024-12-05T21:17:28Z")

</div>

> [@TobiasEigen](#):
>
> It should work but is risky because any change will be overwritten with the next rebuild of AIO.

Well, I’m no Docker expert, but I’d say if your attempt to update imagemagick is successful, the biggest risk after an AIO update is that the state will be the same as it was before and you will have to redo your changes. On the other hand, if your attempt goes completely sideways, you could end up with no preview generation at all until the next update. But I guess you could always force-recreate the container in case you messed it up 😉

Either way, I wouldn’t recommend to test things like that on your productive instance, but setting up a separate test instance for that.

---

<div class="post-metadata">

**Author:** ![TobiasEigen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/tobiaseigen/32/79976_2.png) [@TobiasEigen](https://help.nextcloud.com/u/TobiasEigen)\
**Post date:** [December 6, 2024, 12:02am UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/12 "2024-12-06T00:02:45Z")

</div>

There was a response on [github](https://github.com/nextcloud/all-in-one/issues/5709#issuecomment-2521650086):

> Hi, this will be fixed by upgrading the underlying OS. See e.g. [#5706](https://github.com/nextcloud/all-in-one/issues/5706)

So I guess there’s nothing to do but wait…

---

<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:** [December 14, 2024, 12:02am UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/13 "2024-12-14T00:02:51Z")

</div>

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

---

<div class="post-metadata">

**Author:** ![rakekniven](https://help.nextcloud.com/user_avatar/help.nextcloud.com/rakekniven/32/67096_2.png) [@rakekniven](https://help.nextcloud.com/u/rakekniven)\
**Post date:** [December 19, 2024, 2:44pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/14 "2024-12-19T14:44:00Z")

</div>



---

<div class="post-metadata">

**Author:** ![TobiasEigen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/tobiaseigen/32/79976_2.png) [@TobiasEigen](https://help.nextcloud.com/u/TobiasEigen)\
**Post date:** [December 19, 2024, 2:47pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/15 "2024-12-19T14:47:03Z")

</div>

Thanks @ncfuser for providing this answer! I will give it a shot. The fix is coming in a future release of AIO but the timeline for that is unclear, so I am keen to find an interim fix.

> [@On another topic](https://help.nextcloud.com/t/213022/1):
>
> hier eine Variante, mit der ich das Problem gelöst habe.
> 
> [kubuntu - How to view iPhone .heic Images after iOS 18 update in Ubuntu 24.04? - Ask Ubuntu](https://askubuntu.com/questions/1531719/how-to-view-iphone-heic-images-after-ios-18-update-in-ubuntu-24-04)
> 
> Damit bekommt man eine aktualisierte libheif library und dann funktionieren previews und Anzeige auch wieder.  
> Vg

The answer from that link:

> Try the libheif ppa which hosts an updated version of libheif (otherwise, later versions of libheif will only appear in the official repositories of later versions of Ubuntu. Non-security updates are not backported). Open a terminal and enter the following commands one by one.
> 
> ```auto
> sudo add-apt-repository ppa:ubuntuhandbook1/libheif
> sudo apt update
> sudo apt full-upgrade
> sudo apt install libheif
> sudo apt install libheif-plugin-libde265 libheif-plugin-aomenc libgd3 libheif1
> 
> ```
> 
> As per the [GitHub issue](https://github.com/strukturag/libheif/issues/1190#issuecomment-2267169527), the version 1.18.2 in the PPA (as of 31st October 2024) should contain the fix for this issue.
> 
> Edit: I verified that it works with the latest version of libheif on Arch Linux. (I tested the example HEIC file in the GitHub issue). Therefore, updating libheif on Ubuntu should fix the issue as well.

I am relying on AIO so will have to find a way to update libheif inside the AIO docker container. Tried this out recently but was not successful. Is there a way to add the above to the command to start the master container? 🤔

---

<div class="post-metadata">

**Author:** ![szaimen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/szaimen/32/63019_2.png) [@szaimen](https://help.nextcloud.com/u/szaimen)\
**Post date:** [December 20, 2024, 12:22pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/16 "2024-12-20T12:22:19Z")

</div>

The AIO containers were just update to Alpine v3.21 which is now released with v10.2.0 Beta. Testing and feedback is welcome! See [GitHub - nextcloud/all-in-one: 📦 The official Nextcloud installation method. Provides easy deployment and maintenance with most features included in this one Nextcloud instance.](https://github.com/nextcloud/all-in-one#how-to-switch-the-channel)

---

<div class="post-metadata">

**Author:** ![TobiasEigen](https://help.nextcloud.com/user_avatar/help.nextcloud.com/tobiaseigen/32/79976_2.png) [@TobiasEigen](https://help.nextcloud.com/u/TobiasEigen)\
**Post date:** [December 20, 2024, 4:57pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/17 "2024-12-20T16:57:33Z")

</div>

I’ve taken the plunge and switched to the beta channel, updated, and now my photo previews are properly showing up again.

🥳

All but one, actually. I’ll see if editing it and reuploading it makes it work again.

> **Raw entry from error log**
>
> {“reqId”:“W1HZm5g2vDmtczpsu4iS”,“level”:3,“time”:“2024-12-20T16:55:53+00:00”,“remoteAddr”:“73.19.12.15”,“user”:“kb2-1”,“app”:“core”,“method”:“GET”,“url”:“/apps/memories/api/image/preview/1650367?c=a5edae67675412b778246036bfc2dc43&x=2560&y=1440&a=1”,“message”:“File: /kb2-1/files/Tobias Photos/2024/12/24-12-14 19-57-25 7555.heic Imagick says:”,“userAgent”:“Mozilla/5.0 (Macintosh; Intel Mac OS X 10\_15\_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36”,“version”:“30.0.4.1”,“exception”:{“Exception”:“ImagickException”,“Message”:“Invalid input: No ‘hvcC’ box (2.106) `/mnt/ncdata/kb2-1/files/Tobias Photos/2024/12/24-12-14 19-57-25 7555.heic’ @ error/heic.c/IsHEIFSuccess/141”,“Code”:425,“Trace”:[{“file”:“/var/www/html/lib/private/Preview/HEIC.php”,“line”:99,“function”:“pingImage”,“class”:“Imagick”,“type”:“-\>”,“args”:[“/mnt/ncdata/kb2-1/files/Tobias Photos/2024/12/24-12-14 19-57-25 7555.heic[0]”]},{“file”:“/var/www/html/lib/private/Preview/HEIC.php”,“line”:56,“function”:“getResizedPreview”,“class”:“OC\Preview\HEIC”,“type”:“-\>”,“args”:[“/mnt/ncdata/kb2-1/files/Tobias Photos/2024/12/24-12-14 19-57-25 7555.heic”,2048,2048]},{“file”:“/var/www/html/lib/private/Preview/GeneratorHelper.php”,“line”:44,“function”:“getThumbnail”,“class”:“OC\Preview\HEIC”,“type”:“-\>”,“args”:[{“ **class** ”:“OC\Files\Node\File”},2048,2048]},{“file”:“/var/www/html/lib/private/Preview/Generator.php”,“line”:337,“function”:“getThumbnail”,“class”:“OC\Preview\GeneratorHelper”,“type”:“-\>”,“args”:[{“ **class** ”:“OC\Preview\HEIC”},{“ **class** ”:“OC\Files\Node\File”},2048,2048]},{“file”:“/var/www/html/lib/private/Preview/Generator.php”,“line”:313,“function”:“generateProviderPreview”,“class”:“OC\Preview\Generator”,“type”:“-\>”,“args”:[{“ **class** ”:“OC\Files\SimpleFS\SimpleFolder”},{“ **class** ”:“OC\Files\Node\File”},2048,2048,false,true,“image/heic”,“”]},{“file”:“/var/www/html/lib/private/Preview/Generator.php”,“line”:119,“function”:“getMaxPreview”,“class”:“OC\Preview\Generator”,“type”:“-\>”,“args”:[{“ **class** ”:“OC\Files\SimpleFS\SimpleFolder”},,{“ **class** ”:“OC\Files\Node\File”},“image/heic”,“”]},{“file”:“/var/www/html/lib/private/Preview/Generator.php”,“line”:86,“function”:“generatePreviews”,“class”:“OC\Preview\Generator”,“type”:“-\>”,“args”:[{“ **class** ”:“OC\Files\Node\File”},[{“width”:2560,“height”:1440,“crop”:false,“mode”:“fill”}],“image/heic”]},{“file”:“/var/www/html/lib/private/PreviewManager.php”,“line”:167,“function”:“getPreview”,“class”:“OC\Preview\Generator”,“type”:“-\>”,“args”:[{“ **class** ”:“OC\Files\Node\File”},2560,1440,false,“fill”,null]},{“file”:“/var/www/html/custom\_apps/memories/lib/Controller/ImageController.php”,“line”:62,“function”:“getPreview”,“class”:“OC\PreviewManager”,“type”:“-\>”,“args”:[{“ **class** ”:“OC\Files\Node\File”},2560,1440,false,“fill”]},{“file”:“/var/www/html/custom\_apps/memories/lib/UtilController.php”,“line”:20,“function”:“OCA\Memories\Controller\{closure}”,“class”:“OCA\Memories\Controller\ImageController”,“type”:“-\>”,“args”:[“\*\*\* sensitive parameters replaced \*\*\*”]},{“file”:“/var/www/html/custom\_apps/memories/lib/Controller/ImageController.php”,“line”:55,“function”:“guardEx”,“class”:“OCA\Memories\Util”,“type”:“::”,“args”:[{“ **class** ”:“Closure”}]},{“file”:“/var/www/html/lib/private/AppFramework/Http/Dispatcher.php”,“line”:208,“function”:“preview”,“class”:“OCA\Memories\Controller\ImageController”,“type”:“-\>”,“args”:[1650367,2560,1440,true,“fill”]},{“file”:“/var/www/html/lib/private/AppFramework/Http/Dispatcher.php”,“line”:114,“function”:“executeController”,“class”:“OC\AppFramework\Http\Dispatcher”,“type”:“-\>”,“args”:[{“ **class** ”:“OCA\Memories\Controller\ImageController”},“preview”]},{“file”:“/var/www/html/lib/private/AppFramework/App.php”,“line”:161,“function”:“dispatch”,“class”:“OC\AppFramework\Http\Dispatcher”,“type”:“-\>”,“args”:[{“ **class** ”:“OCA\Memories\Controller\ImageController”},“preview”]},{“file”:“/var/www/html/lib/private/Route/Router.php”,“line”:302,“function”:“main”,“class”:“OC\AppFramework\App”,“type”:“::”,“args”:[“OCA\Memories\Controller\ImageController”,“preview”,{“ **class** ”:“OC\AppFramework\DependencyInjection\DIContainer”},{“id”:“1650367”,“\_route”:“memories.image.preview”}]},{“file”:“/var/www/html/lib/base.php”,“line”:1003,“function”:“match”,“class”:“OC\Route\Router”,“type”:“-\>”,“args”:[“/apps/memories/api/image/preview/1650367”]},{“file”:“/var/www/html/index.php”,“line”:24,“function”:“handleRequest”,“class”:“OC”,“type”:“::”,“args”:}],“File”:“/var/www/html/lib/private/Preview/HEIC.php”,“Line”:99,“message”:“File: /kb2-1/files/Tobias Photos/2024/12/24-12-14 19-57-25 7555.heic Imagick says:”,“exception”:,“CustomMessage”:“File: /kb2-1/files/Tobias Photos/2024/12/24-12-14 19-57-25 7555.heic Imagick says:”},“id”:“6765a1af6b3d6”}

---

<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:** [December 28, 2024, 4:58pm UTC](https://help.nextcloud.com/t/does-imagemagick-need-an-update-to-support-heic-photos-from-latest-ios/211631/18 "2024-12-28T16:58:17Z")

</div>

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