Websites & apps

Web servers, WordPress, PHP, Node.js, SSL and app hosting.

52 guides · page 2 of 3

  • How to migrate a website from Apache to Nginx

    Move a site from Apache to Nginx with low downtime - convert virtual hosts and.htaccess rewrites, set up PHP-FPM, reuse SSL certificates, test on a spare port, then switch.

    AdvancedLinux server5 min read
  • Install Apache (httpd) on AlmaLinux and Rocky Linux

    Install the Apache web server on AlmaLinux or Rocky Linux 8 and 9 with dnf, open HTTP and HTTPS in firewalld, learn the conf.d layout and set SELinux labels for custom web roots.

    BeginnerLinux server5 min read
  • Install multiple PHP versions on Ubuntu and Debian

    Add Ondřej Surý's PHP repository, install PHP 8.2, 8.3 and 8.4 side by side with PHP-FPM, and switch the command-line PHP version with update-alternatives.

    IntermediateLinux server5 min read
  • Install PHP 8.x on AlmaLinux and Rocky Linux with Remi

    Enable EPEL and the Remi repository on AlmaLinux or Rocky Linux 8 and 9, choose a PHP module stream, install PHP-FPM with common extensions, and run extra PHP versions side by side.

    IntermediateLinux server4 min read
  • Load balance backends with Nginx upstream

    Spread traffic across several app instances or servers with an Nginx upstream block, choose round robin, least_conn or ip_hash, and add passive health checks and keepalive.

    AdvancedLinux server5 min read
  • Next.js static export: host a Next.js site on any web hosting

    Turn a Next.js app into plain HTML, CSS and JS with output: export, upload the out folder to public_html and fix routing, images and trailing slashes.

    BeginnercPanel hosting2 min read
  • Nginx 301 redirects and rewrite rules explained

    Learn when to use return and when to use rewrite in Nginx, then redirect single pages, whole folders and old domains, and convert common.htaccess rules.

    IntermediateLinux server5 min read
  • Nginx vs Apache vs OpenLiteSpeed for WordPress on a VPS

    A practical comparison of Nginx, Apache and OpenLiteSpeed for WordPress on a VPS, covering.htaccess support, caching, memory use and ease of setup, with a clear pick for each situation.

    BeginnerLinux server6 min read
  • Node.js environment variables: .env files, cPanel and PM2

    Set environment variables for Node.js apps safely using .env files, the cPanel Setup Node.js App screen, PM2 ecosystem files and systemd, and read them in code.

    BeginnercPanel hosting and Linux VPS2 min read
  • Node.js logs and debugging on cPanel and a VPS

    Find where your Node.js app writes its logs on cPanel, PM2 and systemd, read crash messages, add useful logging and debug safely in production.

    IntermediatecPanel hosting and Linux VPS2 min read
  • Node.js WebSockets behind Nginx, Apache, LiteSpeed or cPanel

    Make Socket.IO or ws WebSockets work behind a reverse proxy: upgrade headers for Nginx, Apache and LiteSpeed, timeouts, wss:// over SSL and cPanel limits.

    AdvancedLinux VPS and cPanel hosting2 min read
  • Password protect a site or folder with Nginx basic auth

    Add a username and password prompt to a whole site, a staging copy or an admin folder with Nginx basic auth, and let trusted IPs through without a password.

    BeginnerLinux server5 min read
  • Proxy WebSocket connections through Nginx

    Make WebSockets work behind Nginx by passing the Upgrade and Connection headers, using a map for connection_upgrade, raising read timeouts, and testing the socket.

    IntermediateLinux server5 min read
  • Rate limit requests in Nginx with limit_req

    Slow down brute-force logins, scrapers and API abuse with Nginx limit_req and limit_conn, using burst and nodelay so real visitors are not affected.

    IntermediateLinux server5 min read
  • Read and manage Nginx access and error logs

    Find Nginx's access and error logs, understand each line, give every site its own log, set error_log levels, pull out top IPs and URLs, and keep logs rotated.

    BeginnerLinux server5 min read
  • Redirect HTTP to HTTPS in Nginx

    Send every plain HTTP visitor to the secure HTTPS version of your site with one return 301 in Nginx, while keeping Let's Encrypt renewals working and avoiding redirect loops.

    BeginnerLinux server5 min read
  • Redirect www to non-www (or the reverse) in Nginx

    Pick one hostname for your site and send every other version to it with a clean 301 redirect in Nginx, keeping HTTPS and the full request path.

    BeginnerLinux server5 min read
  • Run PHP and WordPress with Caddy and PHP-FPM

    Serve PHP sites and WordPress from Caddy using the php_fastcgi directive and PHP-FPM, with working permalinks, larger upload limits and wp-config.php kept private.

    IntermediateLinux server5 min read
  • Run PHP-FPM with Apache using proxy_fcgi and mpm_event

    Move Apache from mod_php and the prefork MPM to PHP-FPM with mpm_event and proxy_fcgi. Use less memory, serve more visitors and pick a PHP version per virtual host.

    IntermediateLinux server4 min read
  • Secure Apache with a free Let's Encrypt certificate

    Install certbot with its Apache plugin, issue free Let's Encrypt certificates for each virtual host, redirect HTTP to HTTPS and confirm that automatic renewal works.

    BeginnerLinux server4 min read

Other topics

Still stuck?

Ask MdmHost AI for a quick answer, or open a ticket and our team will take a look. We are here 24/7.