How to Schedule Blocks in WordPress (Step by Step)

|

|

Have you ever wanted the power to schedule when content is visible on your website? You may know how to schedule posts using the core WordPress publishing functionality, but what about individual blocks within a post or page?

In this tutorial, we will show you how to effortlessly schedule any WordPress block using the 100% free Block Visibility plugin. You will also learn how to add advanced day-of-week and time-of-day recursion with the Pro add-on.

Please note that this tutorial applies to the Block Editor, also known as Gutenberg. Block Visibility was designed exclusively for blocks and does not work in the Classic Editor.

Why Schedule Content in WordPress?

Scheduling content within a page or post is not a new concept. There are many useful applications for this functionality, especially for marketing purposes. However, in the past, complicated shortcodes or third-party interfaces were often required. This barrier made content scheduling reserved for only the most sophisticated WordPress users.

Well, not anymore!

The Block Editor, coupled with the Block Visibility plugin, makes scheduling content incredibly easy and requires zero coding skills. Whether you’re running an online store or writing a personal blog, there are so many ways you can benefit from content scheduling. Best of all, it’s free!

Here are a few examples to get you started.

  1. Running a sale that starts at midnight? Schedule all promotional content to automatically display at 12:00 am. No need to stay up late and manually publish website updates.
  2. Automate the public release of material for your upcoming presentation or online course. Keep your content hidden until the course or presentation has started. 
  3. Going on vacation next week? Set a timed “away” message on your blog to let your followers know you’ll be gone for a bit. Just like an “out of office” email reply.

That’s just the tip of the iceberg. Creativity is your only limitation.

How to Schedule Blocks

Now that we have addressed the “why”, let’s show you how easy it is to create scheduled blocks. Watch the quick video tutorial below, or if you prefer written instructions, continue reading.

Video Overview

Step 1: Create Your Block Content

The first step in building a scheduled block is to create the block content itself. Simply add your content to the Block Editor as you normally would. Any block will do.

In the screenshot below, we are using a Cover block to display a promotional banner for an upcoming hiking excursion on our “outdoor adventure” website.

Adding the promotional banner that needs to be scheduled.
Create the promotional banner that needs to be scheduled.

Step 2: Schedule the Block

With the content complete, we can proceed with applying visibility conditions to the blocks. Here we will apply the settings to the Cover block. All blocks inside the Cover block will respect the visibility settings.

With the Cover block selected, simply navigate to the Visibility panel in the Settings Sidebar.

Ensure that the Date & Time control is enabled. Then select the start and stop dates for the promotion. In this example, we want the start time to be 9:00 am on August 3, 2021. The promotion will end at noon on August 31, 2021.

Configuring the Date & Time control with the designed schedule.
Configuring the Date & Time control with the designed schedule.

Now just update the page and the promotional banner will be successfully scheduled!

Step 3: Add Recursion (Optional)

Standard block scheduling is included in the free Block Visibility plugin. Once you are comfortable with scheduled content, you may find yourself needing more flexibility. That’s where the Pro add-on comes in.

With Block Visibility Pro, you can also add day-of-week and time-of-day recursion settings. With Pro enabled, you will see two new icons in the Date & Time control.

Date & Time recursion settings in Block Visibility Pro.
Date & Time recursion settings in Block Visibility Pro

Let’s assume that we want our promotion to only be visible Monday through Friday between 9:00 am and 5:00 pm. The Cover block should be hidden at all other time periods.

Click on the “recursion” icon to enable day-of-week restrictions. Select Monday through Friday. Then click on the “clock” icon to add time-of-day restrictions. Add a time interval for 9:00 am through 5:00 pm. The setup should look like the screenshot below.

Configured recursion settings in Block Visibility Pro
Configured recursion settings in Block Visibility Pro

With just a few clicks, our promotion is now fully scheduled with both day-of-week and time-of-day recursion.

Want to get even more complicated? Add another complete schedule and/or multiple time intervals! The options are endless.

Tips and Tricks for Scheduling Blocks

While reading through the content above, you may have a few questions. Hopefully, we have captured most of them here. If not, leave a comment below!

How do time zones work with scheduled blocks?

Block scheduling is based the date and time settings for your WordPress installation. Make sure the site is using your preferred time zone. At this time, the plugin does not dynamically detect the time zones of visitors to your website.

How do I unschedule a block?

If you have added a schedule to a block and would like to remove it, simply click on the trashcan icon to clear the schedule. You can also disable the Date & Time control entirely from the plugin settings.

Is there a way to create default content when the scheduled block is hidden?

Absolutely! Simply create the default block(s) in the Block Editor. Then schedule the default content to be visible when the primary content isn’t.


We hope this article has shown you just how easy it is to create scheduled blocks in WordPress using the Block Visibility plugin. If you haven’t already, download the plugin for free on WordPress.org.

If you want to stay updated on all future tutorials and plugin news, please consider subscribing to our YouTube Channel or following us on Twitter.

Until next time…


Nick Diego Avatar

Nick is the creator of Block Visibility. He is also an active WordPress contributor and Developer Advocate focusing on block-based WordPress. You can follow him on Twitter or reach out in WordPress Slack at @ndiego.

Share Your Thoughts

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

Recent Posts

Ready to try Block Visibility?

Unlock the power of the Block Editor with location controls, advanced block scheduling, and more!