How to Enable Memcached on Your Joomla Site

KamHost – Best Web Hosting: Fast, Reliable & Affordable Solutions - Visit: https://kamhost.com

You can significantly speed up your Joomla site by using Memcached. This powerful caching system stores frequently accessed data in memory, reducing database load and improving page load times.

Looking for reliable Joomla hosting? KamHost offers optimized Joomla hosting plans with Memcached pre-configured and ready to use. [Learn more about our Joomla hosting →]

Prerequisites

Before you begin, make sure:

  • ✅ Memcached is enabled on your hosting account – How to Enable Memcached on Your Hosting Plan
  • ✅ You have FTP or file manager access to your Joomla site’s root folder
  • ✅ You have administrator access to your Joomla admin panel

Step 1: Edit the Joomla Configuration File

To enable Memcached on Joomla, you need to modify a few settings in your Joomla configuration.php file first.

Locate the File

You can find this file in your Joomla site’s root folder (usually /www/yourdomain.com/ or the folder where Joomla is installed).

Edit the File

Using your favorite FTP software or the File Manager in your hosting control panel:

  1. Open the configuration.php file for editing.
  2. Find the following lines:

php

public $caching = '0';
public $cache_handler = 'file';
  1. Change these lines to:

php

public $caching = '2';
public $cache_handler = 'memcache';
  1. Immediately after the two lines you edited, add these two lines:

php

public $memcache_server_host = '/home/sys/memcached.sock';
public $memcache_server_port = '0';
  1. Save the file and close it.

Note: This guide is written for KamHost hosting, which uses a Unix socket for Memcached connections. If your hosting provider uses a different socket path or TCP/IP instead of a socket, replace /home/sys/memcached.sock with your specific host details (e.g., 127.0.0.1 and port 11211).

Step 2: Configure Memcached in Joomla Settings

Now, we’ll configure Memcached in your Joomla site’s admin panel.

  1. Log in to your Joomla admin panel.
  2. Navigate to System → Global Configuration.
  3. Click on the Server tab at the top.
  4. Scroll down to Cache Settings.
  5. From the drop-down menu, select Persistent (Memcached).
  6. Enter your Memcached server details:
SettingValue
Memcache(d) Server Host/home/sys/memcached.sock
Memcache(d) Server Port0
  1. Click Save at the top to apply your changes.

Step 3: Verify Memcached Is Working

To confirm Memcached is active on your Joomla site:

  1. Visit your Joomla site’s frontend and browse a few pages.
  2. Check if pages load faster – you should notice improved performance.
  3. You can also check your hosting control panel’s Memcached statistics to see cache hits.

Need help? If you’re unsure whether Memcached is working, contact our support team.

Troubleshooting

IssueSolution
Memcached option not showingThe Memcached extension isn’t enabled on your server. Contact support.
Site breaks after changesCheck your configuration.php for syntax errors and revert to backup.
No performance improvementVerify your Memcached server host and port are correct.
Connection refused errorMemcached service may not be running. Contact your hosting provider.

Benefits of Using Memcached on Joomla

BenefitImpact
🚀 Faster page loadsPages load up to 5x faster with cached data
📉 Reduced server loadFewer database queries = better server performance
📈 Handle more trafficServe more visitors without slowing down
⚡ Better user experienceFaster sites keep visitors engaged

Get Started with KamHost Joomla Hosting

Ready to take your Joomla site to the next level? KamHost offers high-performance Joomla hosting with Memcached pre-installed and ready to enable.

  • ✅ Free Memcached instances on all plans
  • ✅ 24/7 Joomla expert support
  • ✅ One-click Joomla installation
  • ✅ Optimized servers for Joomla performance

[Explore KamHost Joomla Hosting Plans →]

Conclusion

You’ve successfully enabled Memcached on your Joomla website! By following these steps, you’ve improved your site’s performance, reduced server load, and created a better experience for your visitors.

Need Help?

If you have questions about enabling Memcached on your Joomla site, our support team is here to help:

  1. Log in to your KamHost hosting control panel.
  2. Go to Help Center → My Tickets.
  3. Submit a ticket with your query.

We’ll get back to you as soon as possible.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top