Skip to Main Content

How to change the date format on WordPress

Divi: the easiest WordPress theme to use

Divi: The best WordPress theme of all time!

With over 901.000 downloads, Divi is the most popular WordPress theme in the world. It is complete, easy to use and comes with more than 62 free templates. [Recommended]

Have you ever wanted to change the date format on WordPress? Maybe you want to shorten the month or hide the year in your website date?

If this is your case, then do not worry, because in this tutorial I will teach you how to change the date format on WordPress.

But before, if you have never installed WordPress discover How to Install a WordPress Blog in 7 Steps et How to search, install and activate a WordPress theme on your blog 

Then back to why we are here.

The date and time in WordPress

By default, WordPress offers a feature that allows users as well as developers to change the date format. It is possible to modify the date format from the " Settings >> General ", On the option" Date Format "And" Time format ».

SETTINGS-chat options

This is where it is possible to modify the time and date format of your website, either by choosing a predefined format, or by directly modifying the format.

Explanation of the date and time characters in WordPress

The date and time format is based on letters of the alphabet, which represent a fraction of a time or date format. For example, the letter " Y "Reference to the year in digital form, so" 2014 ". For example for "y", "14" will be displayed.

Discover How to display the date of an article update

Here are some concrete examples on the use of time and date formats.

  • « M d, Y : Will display Nov 10, 2014
  • « D M, Y : Will display 10 Nov, 2014
  • « F jS, Y : Will display November 10, 2014
  • « l, F jS, Y : Will show Tuesday, November 10, 2014
  • « H: i: s : Will display 10: 11: 30

You can try several custom sizes in the " custom "Located at the end of the option" Date Format "And" Time format ».

customization-de-la-date-and-the-time

Once you've added your custom size, save your settings. This format will be used everywhere on your blog, until your WordPress theme decides to use another custom format.

Easily create your website with Elementor

Elementor allows you to easily create any website design with a professional look. Stop paying expensive for what you can do yourself. [Free]

Another question commonly asked about date and time is how to display the time just after dates in WordPress posts.

The most difficult solution, but certainly the best one is to change the theme by creating a " Child Theme And add the following line where you want to display the time.

<? php get_the_time ();?>

This code will retrieve the time for a page or an article.

All the time, most beginners do not want to create a child theme (child theme) and access the source code directly.

See by the way How to display the modification date of an article on WordPress

Technically, when WordPress displays dates, it displays the full date and time format. However, most users use the format that only displays the date, which is why this short format was preferred. If you add the corresponding letters to the time in the date format, well the time will also be displayed.

For example: "D / m / Y g: i": will display 10 / 11 / 2014 11: 15

Also, you can use the date format in the time field to produce the same result.

Discover How to display the date of last connection to a user on WordPress

Depending on your needs, there are several things you can do with the date and time in WordPress. For example, you can display the last modified date of an article, instead of the published date.

Are you looking for the best WordPress themes and plugins?

Download the best plugins and WordPress themes on Envato and easily create your website. Already more than 49.720.000 downloads. [EXCLUSIVE]

Go further with How to remove the dates of comments on WordPress

Discover also some premium WordPress plugins  

You can use other WordPress plugins to give a modern look and optimize the grip of your blog or website.

We offer you here some premium WordPress plugins that will help you do that.

1. WordPress Thumby Related Posts Widget

WP Thumby Related Posts plugin can help you improve your WordPress website statistics and especially your visitors' engagement by setting up a landing page that leads them to other relevant and similar content. WordPress Thumby Related Posts Widget

You can get more page views for the price of one. Thanks to this plugin, when visitors come to your website, very nice and high quality thumbnails grab their attention to offer them other useful things on the website.

Download | Demo | Web hosting

2. OptinSpin

OptinSpin for WooCommerce converts visitors to the website into subscribers and customers. Many marketing tools have been released over the past century to increase sales. Optin Spin was created with the same concept but with a different approach.

OptinSpin Fortune Wheel Integrated With WordPress WooCommerce and Easy Digital Downloads Coupons

Using the classic fortune wheel, OptinSpin can engage your customers with its many options. It is fully integrated with the coupons WooCommerce to automate the processes you already know and make them easy and exciting for both the website owner and the customer.

With OptinSpin's easy settings, you can connect your mailing list directly to your MailChimp campaigns, Mailster, Remarkety, Zapier or Active. Optinspin also provides customizable email templates in the backend.

3. WP Instant Search & Auto Suggest

The WordPress WP Instant Search & Auto Suggest plugin allows you to instantly get suggestions for articles, pages, and custom post types when searching your WordPress blog. WP Instant Search Auto Suggest

It works perfectly with plugins Visual Composer et Cornerstone. Its features include: full-screen search, instant search in custom publication types, three built-in design styles, and fully customizable settings.

Download | Demo | Web hosting

Easily create your Online Store

Download free WooCommerce, the best e-commerce plugins to sell your physical and digital products on WordPress. [Recommended]

Recommended Resources

Find out about other recommended resources to help you build and manage your website.

Conclusion

Here ! That's it for this little guide on using time and date formats in WordPress. Do not hesitate to share with your friends on your favorite social networks

However, you will also be able to consult our resources, if you need more elements to carry out your projects of creation of Internet sites, by consulting our guide on the WordPress blog creation.

If you have suggestions or remarks, leave them in our section Comments.

...  

This article features 7 comments

  1. Hello,
    I have succeeded in updating the day and time in French format in the comments, but I cannot translate the "at" which is in the middle: November 24, 2017 at 15:34 pm.
    Does anyone have a solution? The wordpress theme used is Islene.
    Thank you very much in advance !
    Camille

      1. Good evening Thierry,
        Thanks for your feedback. Unfortunately, I don't have a .pot file on this topic 🙁 nor .po in order to do a translation. I have so far translated everything in the .php files but cannot find this "at" 🙁

  2. Dear friends BlogPasCher,

    Regarding the date of the articles, I have a question for you.
    How do you do the miracle of not having the date displayed next to a result about you after a search in google?

    All other sites that date.

    Thank you for your reply.

    1. Hello,
      The date of the articles will be displayed on search engine results, if this information is part of the microdata that can be used by SEO.

      The choice to display this information varies from blog to blog.

      On blogPasCher we do not use the date.

      Goods.

Leave a comment

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

This site uses Akismet to reduce unwanted. Learn more about how your comments data is used.

Back To Top
9 shares
Share7
tweet1
Save1