{"id":48016,"date":"2024-03-27T12:30:00","date_gmt":"2024-03-27T17:30:00","guid":{"rendered":"https:\/\/www.rosehosting.com\/blog\/?p=48016"},"modified":"2024-12-16T01:36:08","modified_gmt":"2024-12-16T07:36:08","slug":"how-to-install-caddy-web-server-on-ubuntu-22-04","status":"publish","type":"post","link":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/","title":{"rendered":"How to Install Caddy Web Server on Ubuntu 22.04"},"content":{"rendered":"<div id=\"bsf_rt_marker\"><\/div>\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04.webp\" alt=\"how to install caddy web server on ubuntu 22.04\" class=\"wp-image-48163\" srcset=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04.webp 1024w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04-300x169.webp 300w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04-150x84.webp 150w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04-768x432.webp 768w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>As a web server, Caddy is a relatively new alternative to Apache and Nginx although it was released initially in 2015. It is an open source web server built using Go language and it uses HTTPS by default. Like any other web server, Caddy can be used as a web server that serves both static and dynamic websites. Caddy offers a versatile and efficient static file server. It can also be used as a robust and scalable reverse proxy. In this tutorial, we will show you how to install Caddy web server on Ubuntu 22.04.<\/p>\n\n\n\n<!--more-->\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-transparent ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-69cc65de219d4\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"ez-toc-cssicon\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-69cc65de219d4\"  aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#Prerequisites\" >Prerequisites<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#Step-1-Log-in-to-your-server-via-SSH\" >Step 1. Log in to your server via SSH<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#Step-2-Install-Dependencies\" >Step 2. Install Dependencies<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#Step-3-Add-Caddy-Repository\" >Step 3. Add Caddy Repository<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#Step-4-Install-Caddy\" >Step 4. Install Caddy<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#Step-5-Configure-Caddy\" >Step 5. Configure Caddy<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#Example-Using-Caddy-with-WordPress\" >Example: Using Caddy with WordPress<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Prerequisites\"><\/span>Prerequisites<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>An <a href=\"https:\/\/www.rosehosting.com\/ubuntu-hosting\/\">Ubuntu 22.04 VPS<\/a><\/li>\n\n\n\n<li>SSH root access or a user with sudo privileges is required<\/li>\n<\/ul>\n\n\n\n<p>Conventions<br># \u2013 given commands should be executed with root privileges either directly as a root user or by using the <code>sudo<\/code> command.<br>$ \u2013 given commands should be executed as a regular user.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Step-1-Log-in-to-your-server-via-SSH\"><\/span>Step 1. Log in to your server via SSH<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>First, you will need to log in to your Ubuntu 22.04 VPS via SSH as the root user:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">ssh root@IP_Address -p Port_number<\/pre>\n\n\n\n<p>You will need to replace &#8216;IP_Address&#8217; and &#8216;Port_number&#8217; with your server&#8217;s respective IP address and SSH port number. Additionally, replace &#8216;root&#8217; with the username of the system user with sudo privileges.<\/p>\n\n\n\n<p>You can check whether you have the proper version of Ubuntu installed on your server with the following command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># lsb_release -a<\/pre>\n\n\n\n<p>It will return an output like this.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">No LSB modules are available.<br>Distributor ID: Ubuntu<br>Description: Ubuntu 22.04 LTS<br>Release: 22.04<br>Codename: jammy<\/pre>\n\n\n\n<p>Then, run the following command to make sure that all installed packages on the server are updated to their latest available versions:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># apt update<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Step-2-Install-Dependencies\"><\/span>Step 2. Install Dependencies<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>There are at least three methods to install Caddy. We can install it by simply downloading the executable binary, install it by compiling the source code, or install it from the repository. In this article, we will show you how to install Caddy using the repository. Since Caddy web server installation requires some packages, we will install the dependencies on our Ubuntu 22.04 system first before starting. Let&#8217;s execute the command below to proceed.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># apt install gnupg curl apt-transport-https debian-keyring debian-archive-keyring -y<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Step-3-Add-Caddy-Repository\"><\/span>Step 3. Add Caddy Repository<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>Before proceeding with the installation, we need to add the GPG key using the following command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># curl -1sLf 'https:\/\/dl.cloudsmith.io\/public\/caddy\/stable\/gpg.key' | gpg --dearmor -o \/usr\/share\/keyrings\/caddy-stable-archive-keyring.gpg<\/pre>\n\n\n\n<p>Then add the repository.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># wget -qO - https:\/\/dl.cloudsmith.io\/public\/caddy\/stable\/debian.deb.txt | sudo tee \/etc\/apt\/sources.list.d\/caddy.list<\/pre>\n\n\n\n<p>Next, do not forget to refresh the package index and get information about the available packages from all enabled repositories.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># apt update<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Step-4-Install-Caddy\"><\/span>Step 4. Install Caddy<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>We added the repository in the previous step and updated the package index. Finally, we can run this command below to install Caddy.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># apt install caddy -y<\/pre>\n\n\n\n<p>That&#8217;s it! You have successfully installed Caddy on your Ubuntu 22.04 system. Upon installation, Caddy will be up and running &#8211; it is already configured to run upon a server reboot. We can check this by running this command below:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># systemctl status caddy<\/pre>\n\n\n\n<p>You can also verify that Caddy is running by trying to access it on your favorite web browser. Navigate to <code>http:\/\/YOUR_SERVER_IP_ADDRESS<\/code> and you will see this:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"729\" src=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/01\/caddy-web-server-1024x729.jpg\" alt=\"\" class=\"wp-image-48017\" srcset=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/01\/caddy-web-server-1024x729.jpg 1024w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/01\/caddy-web-server-300x214.jpg 300w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/01\/caddy-web-server-150x107.jpg 150w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/01\/caddy-web-server-768x547.jpg 768w, https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/01\/caddy-web-server.jpg 1251w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Step-5-Configure-Caddy\"><\/span>Step 5. Configure Caddy<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>At this point, Caddy is running, and you can access it on port 80. To host your website, we can modify <code>\/etc\/caddy\/Caddyfile<\/code> to create the virtual host. Let&#8217;s edit it to host your simple website.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># nano \/etc\/caddy\/Caddyfile<\/pre>\n\n\n\n<p>Append the following lines into the file:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">yourdomain.com {\n\n\troot * \/var\/www\/html\n\tfile_server\n\tlog {\n        output file \/var\/log\/caddy\/access.log\n        format console\n\t}\n}<\/pre>\n\n\n\n<p>Remember to replace <code>yourdomain.com<\/code> with your actual domain or subdomain name that is already pointing to your server. Save the file then exit from the editor.<\/p>\n\n\n\n<p>To apply the new changes, we need to restart Caddy.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># systemctl restart caddy<\/pre>\n\n\n\n<p>Wait for around a minute and Caddy should be already serving your website in HTTPS mode. If your domain or subdomain DNS record is not pointing to your Caddy server, then it will serve in HTTP mode.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Example-Using-Caddy-with-WordPress\"><\/span>Example: Using Caddy with WordPress<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>If you want to host a CMS on your domain\/subdomain &#8211; for example WordPress &#8211; we can continue to the next steps. Let&#8217;s install MariaDB and PHP.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># apt install mariadb-server php-{curl,fpm,imagick,mbstring,mysql,xml,zip}<\/pre>\n\n\n\n<p>Once installed, MariaDB and PHP-FPM should be up and running. Let&#8217;s proceed with creating a database.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># mysql<\/pre>\n\n\n\n<p>Run these commands in MySQL shell.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">mysql&gt; CREATE DATABASE wpcaddy;\nQuery OK, 1 row affected (0.00 sec)\n\nmysql&gt; CREATE USER 'wpcaddy'@'localhost' IDENTIFIED BY 'm0d1fyth15';\nQuery OK, 0 rows affected (0.01 sec)\n\nmysql&gt; GRANT ALL PRIVILEGES ON wpcaddy.* TO 'wpcaddy'@'localhost';\nQuery OK, 0 rows affected (0.01 sec)\n\nmysql&gt; flush privileges;\nQuery OK, 0 rows affected (0.00 sec)\n\nmysql&gt; \\q<\/pre>\n\n\n\n<p>Next, let&#8217;s edit our Caddy file. Remove the lines from the previous step or add the following lines in to <code>\/etc\/caddy\/Caddyfile<\/code><\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">yourdomain.com {\n\n\troot * \/opt\/caddy\n\tfile_server\n\tencode zstd gzip\n\tphp_fastcgi unix\/\/run\/php\/php8.1-fpm.sock \n\t\n\tlog {\n        output file \/var\/log\/caddy\/access.log\n        format console\n\t}\n}<\/pre>\n\n\n\n<p>Save the file then exit. Please note that you need to restart Caddy every time you make changes to your Caddyfile.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># systemctl restart caddy<\/pre>\n\n\n\n<p>Next, we need to download WordPress core files. You can <a href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-and-use-wp-cli-on-a-linux-vps\/\" target=\"_blank\" rel=\"noreferrer noopener\">install and use WP-CLI<\/a> if you want, but in this article, we will use <code>wget<\/code> instead. If your server lacks the <code>wget<\/code> package, you can install it using <code>apt install wget<\/code>. Let&#8217;s download, extract and correct the permissions.<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\"># cd \/opt\/caddy\n# wget https:\/\/wordpress.org\/latest.tar.gz\n# tar -xzvf latest.tar.gz --strip-components 1\n# chown -R www-data: \/opt\/caddy<\/pre>\n\n\n\n<p>That&#8217;s it all, you should be able to access <code>HTTPS:\/\/yourdomain.com<\/code> to finalize your WordPress installation.<\/p>\n\n\n\n<p>Of course, you don\u2019t have to spend your time following this article to install Caddy web server on Ubuntu 22.04. Instead, if you have an active <a href=\"https:\/\/www.rosehosting.com\/ubuntu-hosting\/\" target=\"_blank\" rel=\"noreferrer noopener\">Managed Ubuntu VPS<\/a> Hosting service with us, you can simply ask our expert Linux admins to install Caddy for you. That will give you lots more time to focus on developing your website or running your business. They are available 24\u00d77 and will take care of your request immediately.<\/p>\n\n\n\n<p>PS. If you liked this post on how to install Caddy web server on Ubuntu 22.04, please share it with your friends on social networks or simply leave a reply below. Thanks.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>As a web server, Caddy is a relatively new alternative to Apache and Nginx although it was released initially in &#8230; <\/p>\n<p class=\"read-more-container\"><a title=\"How to Install Caddy Web Server on Ubuntu 22.04\" class=\"read-more button\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#more-48016\" aria-label=\"Read more about How to Install Caddy Web Server on Ubuntu 22.04\">Read More<\/a><\/p>\n","protected":false},"author":4,"featured_media":48163,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2072,13,1698,1707],"tags":[1543,59],"class_list":["post-48016","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-open-source","category-tutorials","category-ubuntu","category-web-servers","tag-caddy","tag-ubuntu","generate-columns","tablet-grid-50","mobile-grid-100","grid-parent","grid-33"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.3) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>How to Install Caddy Web Server on Ubuntu 22.04 | RoseHosting<\/title>\n<meta name=\"description\" content=\"Caddy is a modern web server built using Go. Its installation is fairly straightforward - we&#039;ll show you how to install Caddy on Ubuntu.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to Install Caddy Web Server on Ubuntu 22.04\" \/>\n<meta property=\"og:description\" content=\"How to Install Caddy Web Server on Ubuntu 22.04 | RoseHosting\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/\" \/>\n<meta property=\"og:site_name\" content=\"RoseHosting\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/RoseHosting\" \/>\n<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/rosehosting.helpdesk\" \/>\n<meta property=\"article:published_time\" content=\"2024-03-27T17:30:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-12-16T07:36:08+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04.webp\" \/>\n\t<meta property=\"og:image:width\" content=\"1024\" \/>\n\t<meta property=\"og:image:height\" content=\"576\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/webp\" \/>\n<meta name=\"author\" content=\"Jeff Wilson\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@rosehosting\" \/>\n<meta name=\"twitter:site\" content=\"@rosehosting\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jeff Wilson\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/\"},\"author\":{\"name\":\"Jeff Wilson\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#\\\/schema\\\/person\\\/7ce77a842fa6a9a7f8efa186f2353713\"},\"headline\":\"How to Install Caddy Web Server on Ubuntu 22.04\",\"datePublished\":\"2024-03-27T17:30:00+00:00\",\"dateModified\":\"2024-12-16T07:36:08+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/\"},\"wordCount\":843,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/02\\\/how-to-install-caddy-web-server-ubuntu-22-04.webp\",\"keywords\":[\"Caddy\",\"ubuntu\"],\"articleSection\":[\"Open-source\",\"Tutorials\",\"Ubuntu\",\"Web Servers\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/\",\"name\":\"How to Install Caddy Web Server on Ubuntu 22.04 | RoseHosting\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/02\\\/how-to-install-caddy-web-server-ubuntu-22-04.webp\",\"datePublished\":\"2024-03-27T17:30:00+00:00\",\"dateModified\":\"2024-12-16T07:36:08+00:00\",\"description\":\"Caddy is a modern web server built using Go. Its installation is fairly straightforward - we'll show you how to install Caddy on Ubuntu.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/02\\\/how-to-install-caddy-web-server-ubuntu-22-04.webp\",\"contentUrl\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2024\\\/02\\\/how-to-install-caddy-web-server-ubuntu-22-04.webp\",\"width\":1024,\"height\":576,\"caption\":\"how to install caddy web server on ubuntu 22.04\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/how-to-install-caddy-web-server-on-ubuntu-22-04\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to Install Caddy Web Server on Ubuntu 22.04\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/\",\"name\":\"RoseHosting.com\",\"description\":\"Premium Linux Tutorials Since 2001\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#organization\",\"name\":\"RoseHosting\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/03\\\/android-chrome-192x192-1.png\",\"contentUrl\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/wp-content\\\/uploads\\\/2022\\\/03\\\/android-chrome-192x192-1.png\",\"width\":192,\"height\":192,\"caption\":\"RoseHosting\"},\"image\":{\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/RoseHosting\",\"https:\\\/\\\/x.com\\\/rosehosting\",\"https:\\\/\\\/www.linkedin.com\\\/in\\\/rosehosting\\\/\"],\"description\":\"RoseHosting is a leading Linux hosting provider, serving thousands of clients world-wide since 2001.\",\"email\":\"info@rosehosting.com\",\"telephone\":\"(314) 275-0414\",\"legalName\":\"Rose Web Services LLC\",\"foundingDate\":\"2001-04-02\",\"numberOfEmployees\":{\"@type\":\"QuantitativeValue\",\"minValue\":\"11\",\"maxValue\":\"50\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/#\\\/schema\\\/person\\\/7ce77a842fa6a9a7f8efa186f2353713\",\"name\":\"Jeff Wilson\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g\",\"caption\":\"Jeff Wilson\"},\"description\":\"An experienced Linux veteran with many years of experience. Helping other Linux admins with frequent Linux and business-related blog posts on the RoseHosting blog. Techie by choice. Loving nature and travel. Happily married and father of two lovely children.\",\"sameAs\":[\"https:\\\/\\\/www.rosehosting.com\",\"https:\\\/\\\/www.facebook.com\\\/rosehosting.helpdesk\"],\"url\":\"https:\\\/\\\/www.rosehosting.com\\\/blog\\\/author\\\/jwilson\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"How to Install Caddy Web Server on Ubuntu 22.04 | RoseHosting","description":"Caddy is a modern web server built using Go. Its installation is fairly straightforward - we'll show you how to install Caddy on Ubuntu.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/","og_locale":"en_US","og_type":"article","og_title":"How to Install Caddy Web Server on Ubuntu 22.04","og_description":"How to Install Caddy Web Server on Ubuntu 22.04 | RoseHosting","og_url":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/","og_site_name":"RoseHosting","article_publisher":"https:\/\/www.facebook.com\/RoseHosting","article_author":"https:\/\/www.facebook.com\/rosehosting.helpdesk","article_published_time":"2024-03-27T17:30:00+00:00","article_modified_time":"2024-12-16T07:36:08+00:00","og_image":[{"width":1024,"height":576,"url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04.webp","type":"image\/webp"}],"author":"Jeff Wilson","twitter_card":"summary_large_image","twitter_creator":"@rosehosting","twitter_site":"@rosehosting","twitter_misc":{"Written by":"Jeff Wilson","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#article","isPartOf":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/"},"author":{"name":"Jeff Wilson","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/person\/7ce77a842fa6a9a7f8efa186f2353713"},"headline":"How to Install Caddy Web Server on Ubuntu 22.04","datePublished":"2024-03-27T17:30:00+00:00","dateModified":"2024-12-16T07:36:08+00:00","mainEntityOfPage":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/"},"wordCount":843,"commentCount":0,"publisher":{"@id":"https:\/\/www.rosehosting.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#primaryimage"},"thumbnailUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04.webp","keywords":["Caddy","ubuntu"],"articleSection":["Open-source","Tutorials","Ubuntu","Web Servers"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/","url":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/","name":"How to Install Caddy Web Server on Ubuntu 22.04 | RoseHosting","isPartOf":{"@id":"https:\/\/www.rosehosting.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#primaryimage"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#primaryimage"},"thumbnailUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04.webp","datePublished":"2024-03-27T17:30:00+00:00","dateModified":"2024-12-16T07:36:08+00:00","description":"Caddy is a modern web server built using Go. Its installation is fairly straightforward - we'll show you how to install Caddy on Ubuntu.","breadcrumb":{"@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#primaryimage","url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04.webp","contentUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2024\/02\/how-to-install-caddy-web-server-ubuntu-22-04.webp","width":1024,"height":576,"caption":"how to install caddy web server on ubuntu 22.04"},{"@type":"BreadcrumbList","@id":"https:\/\/www.rosehosting.com\/blog\/how-to-install-caddy-web-server-on-ubuntu-22-04\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.rosehosting.com\/blog\/"},{"@type":"ListItem","position":2,"name":"How to Install Caddy Web Server on Ubuntu 22.04"}]},{"@type":"WebSite","@id":"https:\/\/www.rosehosting.com\/blog\/#website","url":"https:\/\/www.rosehosting.com\/blog\/","name":"RoseHosting.com","description":"Premium Linux Tutorials Since 2001","publisher":{"@id":"https:\/\/www.rosehosting.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.rosehosting.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.rosehosting.com\/blog\/#organization","name":"RoseHosting","url":"https:\/\/www.rosehosting.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/android-chrome-192x192-1.png","contentUrl":"https:\/\/www.rosehosting.com\/blog\/wp-content\/uploads\/2022\/03\/android-chrome-192x192-1.png","width":192,"height":192,"caption":"RoseHosting"},"image":{"@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/RoseHosting","https:\/\/x.com\/rosehosting","https:\/\/www.linkedin.com\/in\/rosehosting\/"],"description":"RoseHosting is a leading Linux hosting provider, serving thousands of clients world-wide since 2001.","email":"info@rosehosting.com","telephone":"(314) 275-0414","legalName":"Rose Web Services LLC","foundingDate":"2001-04-02","numberOfEmployees":{"@type":"QuantitativeValue","minValue":"11","maxValue":"50"}},{"@type":"Person","@id":"https:\/\/www.rosehosting.com\/blog\/#\/schema\/person\/7ce77a842fa6a9a7f8efa186f2353713","name":"Jeff Wilson","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/0985fed6af04cc60703d2ecf27c65dfa373e0ca00eb21c0b03477e099ea3f99f?s=96&r=g","caption":"Jeff Wilson"},"description":"An experienced Linux veteran with many years of experience. Helping other Linux admins with frequent Linux and business-related blog posts on the RoseHosting blog. Techie by choice. Loving nature and travel. Happily married and father of two lovely children.","sameAs":["https:\/\/www.rosehosting.com","https:\/\/www.facebook.com\/rosehosting.helpdesk"],"url":"https:\/\/www.rosehosting.com\/blog\/author\/jwilson\/"}]}},"_links":{"self":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/48016","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/comments?post=48016"}],"version-history":[{"count":8,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/48016\/revisions"}],"predecessor-version":[{"id":49810,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/posts\/48016\/revisions\/49810"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/media\/48163"}],"wp:attachment":[{"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/media?parent=48016"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/categories?post=48016"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rosehosting.com\/blog\/wp-json\/wp\/v2\/tags?post=48016"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}