How to add the year to the post title WordPress update 2022, if your article is content that is regularly updated, it is very necessary to add a timeline to the article title, this is not Not only beneficial for Seo but also makes users feel more “trusted” with the content you are looking for, make sure that when looking for something, if the title contains a timeline, you will choose the article. write it even though it’s not at number 1 right?
Contents
Add the year to the WordPress post title
This tip is quite suitable for Blogs that provide discount codes or Product Review Blogs, Technology Blogs… or any other category you can apply this tip to highlight your content. So how to add the year to the WordPress post title? In this article, I will show you with 3 pretty simple methods for you to add the year of your WordPress post title.
Enable display of shortcode content on title
First to add the year to the WordPress post title you need to enable the shortcode display on the title because by default on the WordPress title you cannot use the shortcode.
To activate you just need to add the following command to File Function.php of the interface you are using.
Once you’re done adding, follow the next steps.
Time shortcode definition
After you enable the display of the shortcode content on the title, next you define the shortcode to take the time. You just need to copy the code below and paste it into File Function.php of the interface you are using.
Display year in title
After implementing the 2 code snippets provided above, you can now use it to add the year to your WordPress post title.
To add the date and year to the title, use the format below.
Example: Latest Tiki discount code June 2022
Note: If you use this method, the header on the browser will display the shortcode and not the date format as in the title.
To fix this, you can combine with the 2 SEO tools below to display the shortcode content in the title and description so that Google can index the shortcode content.
Use Yoast SEO
If you are using the Yoast SEO Plugin as an SEO tool for your website, then you can add the year to your WordPress post title by doing the following.
First, add these 2 snippets to File Function.php to trigger the display of the shortcode content in the title and description of Yoast SEO so that Google can index the shortcode content.
Next, you just need to define the shortcode in the post title according to this structure.
You will now get the desired result, you will see the date appear in the title and on the status tab of the browser.
Use Rank math
If you are using the Rank math plugin to do SEO for your website then you can add the year to your WordPress post title by doing the following.
Similarly, first add these 2 snippets to File Function.php to enable the display of the shortcode content in the title and description of Rank math so that Google can index the shortcode content.
Next, you just need to define the shortcode in the post title according to this structure.
You will now get the desired result, you will see the date appear in the title and on the status tab of the browser.
How to use shortcodes?
In the post title, you just need to set the title according to the syntax above, you can display the date and year in the WordPress post title.
For example: I want to add “year” to this article, then I will name it as shown below.
![How to add the year of the post title WordPress update [male] 1 how to add men to enter viet nam wordpress](https://i.imgur.com/U1GDmqq.jpg)
After I save the post to the homepage I will see the results automatically show “year” as shown below.
![How to add the year of the post title WordPress update [male] 2 How to add the year of the post title WordPress update [male] 1](https://i.imgur.com/4ITvgy8.jpg)
Okay! So you can automatically add the year to the WordPress post title, you just need to follow the structure below to be able to automatically customize the date and year in the WordPress title.
Conclusion
So I have guided you in quite detail on how to automatically add the year of the WordPress post title ? Do you feel WordPress tips or not? If you have other great WordPress tips you can share with everyone by leaving a comment below, have fun.

