Websites & apps

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

83 guides · page 4 of 5

  • 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
  • Set browser caching headers (expires and Cache-Control) in Nginx

    Tell browsers how long to keep images, CSS, JavaScript and fonts with expires and Cache-Control in Nginx, while making sure HTML stays fresh after every update.

    BeginnerLinux server5 min read
  • Set browser caching in Apache with mod_expires and headers

    Tell browsers how long to keep your files. Use mod_expires and Cache-Control headers in Apache to cache versioned assets for a year and keep HTML fresh.

    BeginnerLinux server4 min read
  • Set up Apache virtual hosts for multiple websites

    Host several websites on one Apache server with name-based virtual hosts. One config file per domain, its own document root and its own logs, on Ubuntu, Debian, AlmaLinux and Rocky Linux.

    BeginnerLinux server5 min read
  • Set up Nginx as a reverse proxy for any backend app

    Put Nginx in front of a Node.js, Python, Go or Java app running on a local port, forward the right headers, tune timeouts and buffering, and add free HTTPS.

    IntermediateLinux server5 min read
  • Show real visitor IPs in Nginx behind Cloudflare or a proxy

    Behind Cloudflare or a load balancer, Nginx sees the proxy's IP instead of your visitors'. Use the real_ip module to restore the real address for logs, rate limits and apps.

    IntermediateLinux server5 min read
  • Tune Apache MPM settings to stop memory exhaustion

    Size Apache's MaxRequestWorkers to the RAM you really have, choose between prefork and event, set ServerLimit and KeepAlive sensibly and spot the MaxRequestWorkers warning in your logs.

    AdvancedLinux server5 min read
  • Tune PHP-FPM pools (pm.max_children) for your RAM

    Size PHP-FPM to your server's memory. Choose between dynamic, ondemand and static, calculate pm.max_children from real per-process memory, set pm.max_requests, and act on the max_children warning.

    AdvancedLinux server6 min read
  • Tune PHP-FPM pools: pm.max_children and process managers

    Calculate pm.max_children from your RAM, choose dynamic, static or ondemand, enable the status page and slow log, and fix 'server reached max_children' warnings.

    AdvancedLinux VPS3 min read
  • Upgrade PHP safely: a checklist for cPanel and VPS sites

    Move a site to a newer PHP version without downtime: check compatibility, test on staging, match extensions and settings, switch per site and know how to roll back.

    IntermediatecPanel hosting · Linux VPS3 min read
  • Upgrade PHP to a newer version on your VPS

    Upgrade a site from PHP 8.1 to 8.3 or 8.4 safely. Install the new PHP-FPM and matching extensions, carry over php.ini changes, switch Nginx or Apache, test, and remove the old version.

    IntermediateLinux server5 min read
  • Use a different PHP version per website in Nginx

    Run each Nginx site on its own PHP version by pointing its server block at a different PHP-FPM socket, give each site a separate pool, and confirm the version without leaving phpinfo exposed.

    IntermediateLinux server4 min read
  • Use Apache as a reverse proxy with mod_proxy

    Put Apache in front of a Node.js, Python or Docker app with mod_proxy. Set ProxyPass and ProxyPassReverse, keep the original host, proxy WebSockets and serve the app over HTTPS.

    IntermediateLinux server4 min read
  • Use Caddy as a reverse proxy for your apps

    Put Caddy in front of Node.js, Python or Docker apps with the reverse_proxy directive, give each app its own subdomain with automatic HTTPS, and add load balancing and health checks.

    BeginnerLinux server5 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.