The “link you followed has expired” is a common error that occurs when trying to upload themes and plugins via the WordPress dashboard.
The error usually happens when the file you’re trying to upload is larger than the default upload and execution limits set by WordPress. The best way to fix the issue is to increase the default upload limits.
In this guide, we’ll show you how to fix the “link you followed has expired” all by yourself in a few easy steps.
What Causes ‘The Link You Followed Has Expired’ Error?
If you were to open the WordPress dashboard and go to Media >> Add New page, you’ll notice that by default WordPress has a fixed upload size limit that prevents you from uploading files of larger sizes.
These prefixed sizes differ based on the type of web hosting plan you use. While managed WordPress hosting providers set over 100mb as the maximum upload size limit, smaller shared hosting plans may limit the size to 25mb. This limit is usually what keeps you from uploading heavy themes and plugins.
Even if your website has a bigger upload size limit, if your website’s maximum execution time is limited, then WordPress will often fail to upload larger files. This is when you encounter fatal errors and other specific issues like “link you followed has expired” error.
How To Fix The Error
To fix the “link you followed has expired” error, all you need to do is to increase the maximum upload size and execution times for your website.
This requires editing a core WordPress file and copying a few lines of code. It can be done in several different ways. We’ll walk you through the process. Remember not to follow all these methods. If one method didn’t work, reverse the changes you’ve made and try the next method. Not all at once!
Note: Backup your website and make copies of files before making any changes to the core WordPress files. Follow this guide to learn how to setup WordPress backups. If you don’t know what you’re doing, seek help from an expert.
Method 1: Edit .htaccess File
The .htaccess file is a core file used by WordPress. We can edit this file and copy our code to change the default upload limits set by WordPress.
To edit the file, you need to access the WordPress files in your server. We’ll show you how to access the server using the CPanel. But, you can also use an FTP client app as well.
Step 1: Login To CPanel
If you can’t find the CPanel via your hosting account, simply type “cpanel” at the end of your website domain name (eg: yourwebsite.com/cpanel).
Then enter the CPanel username and password. These details are usually provided to you in the welcome email your hosting provider sends to you.
Step 2: Find And Open The File Manager
In the CPanel, find and open the File Manager app. Then it will prompt you where you want to navigate to. Choose to open the public.html folder.
Step 3: Copy The Code
On the public.html folder you’ll see the .htaccess file. Right-click on this file and choose Edit.
Then copy and paste the following lines of code at the end of the .htaccess file
php_value upload_max_filesize 64M
php_value post_max_size 64M
php_value max_execution_time 300
php_value max_input_time 300
Once you’re done, click Save.
This method usually fixes the error. If it didn’t work, try the next method.
Method 2: Create A PHP.ini File
If editing the .htaccess file didn’t work, you can create and upload a PHP.ini file into your server to fix the issue.
Some hosting servers will automatically create a PHP.ini file in your server. Follow the steps detailed in the previous method to navigate to the public.html folder in your server and see if there’s already a PHP.ini file in your server.
If not, let’s create one.
Step 1: Create A PHP.ini file
The PHP.ini file has to be created locally on your computer and then you can upload it to your server.
First, open a blank notepad and copy and paste the following lines of code into it.
upload_max_filesize = 64M
post_max_size = 64M
max_execution_time = 300
Then Save the note file as php.ini and choose file type as “All Files”
Step 2: Upload The File
Navigate back to your server and go to the public.html folder. Then upload the PHP.ini file that you’ve just created on your computer.
This will fix the error and increase the upload size limits to 64MB.
In Conclusion
These methods should help fix the issue and allow you to upload themes and plugins with larger sizes through the WordPress dashboard.
However, some shared hosting providers may have restrictions that will prevent you from uploading large files. If the issue persists, contact your web hosting provider and ask for their help.
In the future, use an FTP client app like Filezilla to directly access your server and upload themes and plugins using the FTP client for easily uploading larger files.
Amaira Sen says
I have solved this error by changing a PHP.ini file and to do so you need to go to wamp> PHP> php.ini file and chnage the configuration to
post_max_size = 750M
upload_max_filesize = 750M
max_execution_time = 5000
max_input_time = 5000
memory_limit = 1000M
Dan says
Can’t find the php.ini and I already tried to create one and upload as suggested but still no working
Paul says
Thanks, editing the php.INI file on the server worked for me.
Rey says
Awesome worked!!
thankyou
Raymond says
upload_max_filesize = 64M
post_max_size = 64M
max_execution_time = 300
Thanks! it did reall works.
Shirsh Mahadik says
Than you so much! Modifying .htaccess, did fix the error.
MShah says
first of all my theme size is 2mb
second i am using (URL removed) so how i access the mentioned/said files
Slobodan says
Free hosting comes with a lot of limitations. It’s highly unlikely you can access settings like that. The only approach is to contact the hosting provider and explain the issue.
king says
Thank you so much! That modifying did the job, continue with good work.
Edin Chavez says
Thank you so much. You are awesome 🙂 That worked perfectly.
Ian says
Thank you. The .htaccess edit you suggested solved the problem I was having straightaway.
dan says
This was just the ticket. Thanks.
Ahmed Ragab says
Really , thanks very much.
Milton says
Thank you so much. Method 1 fixed the problem. Stay Safe!
Winston says
thank you, the .htaccess change worked for me.
Emerald says
God bless u bro…God bless! It worked
nikki says
it worked Thanks alot 🙂 🙂
php_value upload_max_filesize 64M
php_value post_max_size 64M
php_value max_execution_time 300
php_value max_input_time 300
Dev Sharma says
Hey Nikki, You’re welcome. Happy to help :).
Dan says
Damn, there’s no .htaccess in my public.html folder
Ravikant Pranitaa says
Hey Bro its great i m learning a lot here…. thanx for ur education…. 1st method worked and solved the issues. Thanx Dear.
James Wazzy says
Thanks to you! I solved this by changing the Php Multi Ini Config, its writes automatically to my .htaccess.
SeMa says
Thank you! I followed Method 1, edited .htaccess file and it worked!