pen paper writing icon WordPress icon png newspaper icon

How to Fix “The Link You Followed Has Expired” Error in WordPress

The Link You Followed Has Expired

Many of us while surfing through the internet see this message “The Link You Followed Has Expired”. Whenever this error message is shown, it does not include detailed information regarding why this error message was displayed. As a result, many individuals find the purpose of the error puzzling. And if you are a newbie in this, it will keep you puzzled even more. With that note, today we will discuss how to fix The Link You Followed Has Expired error.

However, this error is most common in WordPress. When you are working on the WordPress admin panel and trying to upload content on the WordPress site, this message might show. So before going into the details, we will like to discuss when this error message is usually displayed.

What Causes the Link You Followed Has Expired Error?

As we mentioned already, this error is usually seen on WordPress while you are working at the admin panel area of your WordPress site. Usually, this error occurs when you try to upload a WordPress theme or plugin to the website. It shows the message in the format given below:

the link you followed has expired

WordPress has few limitations on the file size you can upload. From the admin area, you cannot upload files that exceed the limit that is set by the WordPress hosting company. So, whenever you try to upload any file from the admin area which is bigger than the mentioned limit, then this error message is shown. Along with that, the setting also displays this message when the scripts start running very long.

If you want to know the limit of the file size that you can upload, you can go to “Media” from the right-hand side menu and click on Add New option. In the bottom left corner of the box, the file limitation will be shown.

maximum upload size

The reason for applying such limitations is to keep your website light. It is for the betterment of the overall performance of the website. Low sized images will help your website to perform fast and also will have a positive effect on loading time. However, if the limitations are very low, and you upload a bigger file, it will show memory exhausted error or maximum execution time exceeded error.

However, in case of uploading WordPress themes or plugins, the “The Link You Followed Has Expired” error is shown.

In the following, we will discuss how we can fix this error.

How to Fix “The Link You Followed Has Expired” Error in WordPress

Increasing the file upload size, PHP memory and execution time limit will quickly solve “The Link You Followed Has Expired” error. In the following, we will discuss the detailed ways of solving this problem. You can pick the method that is most suitable and feasible for you and try to fix the error.

Fix 1: Increase limits of functions.php files.

By increasing the limits of the functions.php files on your website, you can increase the file size limit. When the file size limits are increased, then you can upload bigger and larger files than before. However, this fixing method comes with a drawback. The change will apply to the theme you are currently using. If you change the theme to a new one, then this fix will no longer work, and your limits will go back to the original limits. You can again apply the same fix on the new theme and get rid of the issue. To fix this issue by increasing the limit, all you have to do is add a code to your WordPress theme’s functions.php files. If you are wondering where to find funtions.php files in WordPress, follow the steps below:

  • Log in to your WordPress admin panel
  • Click on the “Appearance” icon on the right-hand side menu.
  • Click on “Theme Editor”
  • On the right-hand side, you will see an option called “Theme Functions”.
  • This is the file where you can input the code.
Theme Function

So, as you have access to the functions.php file now, you have to copy-paste a code to increase the limitation of the theme. Use the following code to increase limits in WordPress.

@ini_set( 'upload_max_size' , '120M' );
@ini_set( 'post_max_size', '120M');
@ini_set( 'max_execution_time', '300' );

You must ensure the values you increase is more than the file you will be uploading on your website. The values can be changed in the upload_max_size and post_max_size area. Along with that, you will require to increase max_execution_time to the estimated time that will be needed for the upload to complete. If uncertain about the amount of time required, you can double the current time value.

Fix 2: Increase limits in .htaccess file.

This is another method that you can use to fix the issue. If you are not a fan of adding code to the functions file of your WordPress theme, then you can try using this method. In this method, you do the required modification from the htaccess.file of your website directly. If you do not know where to find the htaccess file. Follow the steps below:

  • Log in to your cPanel.
  • Go to the File Manager.
  • In the file manager section, you will find the htaccess.file to edit.

You can also edit the htaccess.file by connecting your website using FTP easily.

htaccess ftp

Once you have found the file, you will have to add the code below at the very bottom of your htaccess file.

php_value upload_max_filesize 128M
php_value post_max_size 128M
php_value max_execution_time 300
php_value max_input_time 300

After you have added the code to the htaccess file, save changes and upload the file back to your website. Once you are done, the changes will be effective on your website.

Fix 3: Increase limit in php.ini file.

The last but certainly not the least method of solving the “the link you followed has expired” error is to update the increased limit on your php.ini file. In can find the php.ini file on your WordPress website through the following method:

  • Connect your WordPress site using an FTP client.
  • Navigate to the root folder. 
  • Look for the php.ini file.

Please note: If you are using shared hosting, you might not find the php.ini file on your route folder. If that is the case, you will have to create a blank php.ini file with a plain text editor such as Notepad and then upload the note pad to your website.

You will have to add the following code to the php.ini file.

upload_max_filesize = 128M
post_max_size = 128M
max_execution_time = 300

After bringing the changes, upload the file back to your website to implement the changes.

If the problem remains, you can increase the limit of the size to ensure the upload of the files will not hamper the process. We hope using any of the methods mentioned above, you can fix this issue quickly, and the “the link you followed has expired” error will no longer show while you are working on WordPress.

Fix 4: Use WordPress Plugin

However, not everyone is comfortable with coding, so the last fix we want to suggest is using a specific plugin. Increase Maximum Upload File Size will make our life easy. With this plugin, you can easily change the limit of the file size and keep on moving with your website. Follow the steps below:

  • Navigate to Dashboard > Plugins > Add new
  • Search for the plugin “Increase Maximum Upload File Size
  • Install and activate plugin
  • Go to the settings section of the plugin
  • Change the value
  • Click on save changes to have immediate effect

With this fix you can also increase the limit and fix the issue.

If you liked the solution we provided, check out our blog for more such informative contents.