Tutorial TOC

Create a WP shortcode

If you wish to embed an Outlook / Exchange Calendar in WordPress, you need to create a WordPress shortcode using the WPO365 shortcode generator.

Perform the following steps to create a WP shortcode to embed an Outlook / Exchange Calendar in WordPress.

Navigate to WP Admin > WPO365 > … > Outlook / Exchange Calendar embed.

Basic configuration options


The basic free version of the embedded Outlook / Exchange Calendar is included in the WPO365 | LOGIN plugin that can be downloaded for free from the WordPress Plugins Directory and the WPO365.com website..


  • Select Users or Groups as your Calendar source.

At this very moment the WPO365 options for embedding an Outlook / Exchange Calendar are “limited” to the default calendar of a user or a Microsoft 365 Group (Teams).


  • Depending on the calendar source that you selected, you then specify the User Principal Name – for example user@domain – or Object ID of the group – for example dbc37da2-xxxx-xxxx-xxxx-xxxxxxxxxxxx – for User principal name or Object ID.

Advanced premium options


Premium options are unlocked by the WPO365 | M365 APPS addon or the WPO365 | INTRANET bundle.

Please note When you upgrade to benefit of any of the premium options, you must create a new shortcode and replace shortcodes that you created with the free version included in the WPO365 | LOGIN plugin.


  • Optionally, you can change the Calendar grouping. By default, calendar events are grouped by month. The alternative options are By day, By week and By year.
  • Optionally, you can change the date range for which events will be fetched. By default, calendar events for the current year between Jan. 1st and Dec. 31st will be fetched. The alternative options are Today, This week, This month, This year and Custom. When you select Custom, you can enter your own start and end date. As start date, you can also check Today to ensure that events that occurred in the past are not shown.

Test your configuration

After you completed your configuration, it’s time to test it by simply clicking Test configuration at the bottom of the generator, followed by the Start test button on new panel that appeared.

Add shortcode to a WordPress page or post

Perform the following steps to add the generated shortcode to a WordPress page or post after you clicked to Copy the short code to clipboard.

  • From the WordPress Admin Bar, click + New to add a new WordPress page or post.
  • On the page or post, type short code in the block navigator and click the short code shortcut to add a new short code block to the page or post.
  • In the short code editor, click Ctrl+V (or right mouse click and click Paste) to paste the short code.
  • Publish the page and then click View post to check the result.

Related Features