Curl is installed, "The CURL extension is required"

I’ve installed Kirby on a server to test.
Using the panel, and I’m getting “The CURL extension is required”.

Details:

Apache/2.4.29 (Ubuntu)

curl -V
curl 7.58.0 (x86_64-pc-linux-gnu) libcurl/7.58.0 OpenSSL/1.1.1 zlib/1.2.11 libidn2/2.3.0 libpsl/0.19.1 (+libidn2/2.0.4) nghttp2/1.30.0 librtmp/2.3
Release-Date: 2018-01-24
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtmp rtsp smb smbs smtp smtps telnet tftp 
Features: AsynchDNS IDN IPv6 Largefile GSS-API Kerberos SPNEGO NTLM NTLM_WB SSL libz TLS-SRP HTTP2 UnixSockets HTTPS-proxy PSL
php -v
PHP 7.4.18 (cli) (built: May  3 2021 11:26:48) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
    with Zend OPcache v7.4.18, Copyright (c), by Zend Technologies

Any ideas?

Check with

php -m

if the PHP version your server is using is the same as which you are using on the command line. This will list the installed PHP modules.

But it is usually better to use phpinfo() to check if the curl extension is present and enabled.

See also: curl vs libcurl

It’s a little strange. My ubuntu server was originally php 7.2, but I installed 7.4 and told the server to use 7.4. So, I get the following outputs:

[PHP Modules]
bcmath
calendar
Core
ctype
date
dom
exif
FFI
fileinfo
filter
ftp
gd
gettext
hash
iconv
json
libxml
mbstring
mysqli
mysqlnd
openssl
pcntl
pcre
PDO
pdo_mysql
pdo_sqlite
Phar
posix
readline
Reflection
session
shmop
SimpleXML
sockets
sodium
SPL
sqlite3
standard
sysvmsg
sysvsem
sysvshm
tokenizer
xml
xmlreader
xmlwriter
xsl
Zend OPcache
zlib

[Zend Modules]
Zend OPcache

But php.info reports:

  • PHP Version 7.4.18
  • and cURL is listed in the modules

Kirby uses extension_loaded('curl') in /kirby/src/Cms/System.php #84 to check for the curl extension.

In phpinfo you should see this section with status enabled: